Skip to content

Commit

Permalink
Merge pull request #1642 from immutable/feature/ID-1487-update-genera…
Browse files Browse the repository at this point in the history
…ted-clients

chore: ID-1487 Updated IMX & MR generated-clients
  • Loading branch information
haydenfowler committed Apr 4, 2024
2 parents 78f3258 + 6beee1d commit 545c6e7
Show file tree
Hide file tree
Showing 36 changed files with 1,220 additions and 585 deletions.
238 changes: 82 additions & 156 deletions packages/internal/generated-clients/src/imx-openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
},
"version": "3.0.0"
},
"host": "api.sandbox.x.immutable.com",
"host": "api.immutable.com",
"basePath": "/",
"paths": {
"/v1/assets": {
Expand Down Expand Up @@ -2362,7 +2362,7 @@
},
"/v1/signable-withdrawal-details": {
"post": {
"description": "Gets details of a signable withdrawal",
"description": "Gets details of a signable withdrawal. This endpoint will be deprecated once StarkEx contract gets upgraded to v4, check https://docs.immutable.com/x/reference/#/operations/getSignableWithdrawalV2.",
"consumes": [
"application/json"
],
Expand Down Expand Up @@ -2985,7 +2985,7 @@
}
},
"post": {
"description": "Creates a withdrawal. Use https://docs.x.immutable.com/reference#/operations/getSignableWithdrawal to get request body params.",
"description": "Creates a withdrawal. Use https://docs.x.immutable.com/reference/#/operations/getSignableWithdrawal to get request body params. This endpoint will be deprecated once StarkEx contract gets upgraded to v4, check https://docs.immutable.com/x/reference/#/operations/createWithdrawalV2.",
"consumes": [
"application/json"
],
Expand All @@ -2995,7 +2995,7 @@
"tags": [
"withdrawals"
],
"summary": "Creates a withdrawal of a token",
"summary": "Creates a withdrawal",
"operationId": "createWithdrawal",
"parameters": [
{
Expand Down Expand Up @@ -3865,7 +3865,7 @@
},
"/v2/withdrawals": {
"post": {
"description": "Creates a withdrawal. Use https://docs.x.immutable.com/reference#/operations/getSignableWithdrawal to get request body params.",
"description": "Creates a withdrawal. Use https://docs.immutable.com/x/reference/#/operations/getSignableWithdrawalV2 to get request body params.",
"consumes": [
"application/json"
],
Expand All @@ -3875,7 +3875,7 @@
"tags": [
"withdrawals"
],
"summary": "Creates a withdrawal of a token for starkex contracts that are higher than v3",
"summary": "Creates a withdrawal of a token for when StarkEx contract that is higher than v3",
"operationId": "createWithdrawalV2",
"parameters": [
{
Expand Down Expand Up @@ -7072,7 +7072,7 @@
"type": "string"
},
"expiration_timestamp": {
"description": "Token in request to match in SDK implementation",
"description": "Expiration timestamp for this withdrawal",
"type": "integer"
},
"nonce": {
Expand Down Expand Up @@ -7593,7 +7593,7 @@
"type": "string"
},
"token": {
"$ref": "#/definitions/mintToken"
"$ref": "#/definitions/mintTokenOAIGen"
},
"transaction_id": {
"description": "Sequential ID of transaction in Immutable X",
Expand Down Expand Up @@ -7678,6 +7678,59 @@
}
}
},
"MintToken": {
"type": "object",
"required": [
"data",
"type"
],
"properties": {
"data": {
"$ref": "#/definitions/mintTokenDataOAIGen"
},
"type": {
"description": "Type of this asset (ETH/ERC20/ERC721)",
"type": "string"
}
}
},
"MintTokenData": {
"type": "object",
"required": [
"quantity",
"quantity_with_fees"
],
"properties": {
"decimals": {
"description": "Number of decimals supported by this asset",
"type": "integer"
},
"id": {
"description": "[DEPRECATED] Internal Immutable X Token ID",
"type": "string"
},
"quantity": {
"description": "Quantity of this asset - inclusive of fees for buy order in v1 API and exclusive of fees in v3 API",
"type": "string"
},
"quantity_with_fees": {
"description": "Quantity of this asset with the sum of all fees applied to the asset",
"type": "string"
},
"symbol": {
"description": "Symbol of a token",
"type": "string"
},
"token_address": {
"description": "Address of ERC721/ERC20 contract",
"type": "string"
},
"token_id": {
"description": "ERC721 Token ID",
"type": "string"
}
}
},
"MintTokenDataV2": {
"type": "object",
"required": [
Expand Down Expand Up @@ -7970,89 +8023,25 @@
"Project": {
"type": "object",
"required": [
"collection_limit_expires_at",
"collection_monthly_limit",
"collection_remaining",
"company_name",
"contact_email",
"id",
"mint_limit_expires_at",
"mint_monthly_limit",
"mint_remaining",
"name"
],
"properties": {
"api_key": {
"description": "API key for the project. This is only for zkevm project. This API is not for increasing rate limit yet.",
"type": "string"
},
"chain_type": {
"description": "The project ChainType",
"type": "string"
},
"collection_limit_expires_at": {
"description": "The current period expiry date for collection limit",
"type": "string"
},
"collection_monthly_limit": {
"description": "The total monthly collection limit",
"type": "integer"
},
"collection_remaining": {
"description": "The number of collection remaining in the current period",
"type": "integer"
},
"company_name": {
"description": "The company name",
"type": "string"
},
"contact_email": {
"description": "The project contact email (must be registered as a developer account with Immutable at https://hub.immutable.com)",
"type": "string"
},
"environment_id": {
"description": "The environment ID",
"type": "string"
},
"environment_name": {
"description": "The user environment name correlating to this project",
"type": "string"
},
"id": {
"description": "The project ID",
"type": "integer"
},
"mint_limit_expires_at": {
"description": "The current period expiry date for mint operation limit",
"description": "The project group ID",
"type": "string"
},
"mint_monthly_limit": {
"description": "The total monthly mint operation limit",
"type": "integer"
},
"mint_remaining": {
"description": "The number of mint operation remaining in the current period",
"type": "integer"
},
"name": {
"description": "The project name",
"description": "The project group name",
"type": "string"
},
"org_id": {
"description": "The organisation ID that the project belongs to",
"type": "string"
},
"project_group_id": {
"description": "Project group id",
"type": "string"
},
"publishable_key": {
"description": "The public publishable_key for the project",
"type": "string"
},
"publishable_key_created_at": {
"description": "The public publishable_key created time",
"type": "string"
}
}
},
Expand Down Expand Up @@ -11794,6 +11783,24 @@
],
"x-go-gen-location": "models"
},
"mintTokenDataOAIGen": {
"description": "Token details of this asset",
"allOf": [
{
"$ref": "#/definitions/MintTokenData"
}
],
"x-go-gen-location": "models"
},
"mintTokenOAIGen": {
"description": "Details of the asset which has been minted",
"allOf": [
{
"$ref": "#/definitions/MintToken"
}
],
"x-go-gen-location": "models"
},
"nftprimarytransaction.CreateAPIRequest": {
"type": "object",
"properties": {
Expand Down Expand Up @@ -13998,87 +14005,6 @@
}
],
"x-components": {
"responses": {
"BadRequest": {
"content": {
"application/json": {
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"description": "Bad Request (400)"
},
"ForbiddenRequest": {
"content": {
"application/json": {
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"description": "Forbidden (403)"
},
"InternalServerError": {
"content": {
"application/json": {
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"description": "Internal Server Error (500)"
},
"NotFound": {
"content": {
"application/json": {
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"description": "The specified resource was not found (404)"
},
"NotImplementedError": {
"content": {
"application/json": {
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"description": "Not Implemented Error (501)"
},
"TooManyRequests": {
"content": {
"application/json": {
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"description": "Too Many Requests (429)"
},
"UnauthorisedRequest": {
"content": {
"application/json": {
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"description": "Unauthorised Request (401)"
},
"UnprocessableEntity": {
"content": {
"application/json": {
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"description": "Unprocessable Entity (422)"
}
}
"responses": {}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,10 @@ models/metadata-schema-request.ts
models/mint-fee.ts
models/mint-request.ts
models/mint-result-details.ts
models/mint-token-data-oaigen.ts
models/mint-token-data-v2.ts
models/mint-token-data.ts
models/mint-token-oaigen.ts
models/mint-token.ts
models/mint-tokens-response.ts
models/mint-user.ts
Expand Down
2 changes: 1 addition & 1 deletion packages/internal/generated-clients/src/imx/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import { Configuration } from "./configuration";
// @ts-ignore
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';

export const BASE_PATH = "https://api.sandbox.x.immutable.com".replace(/\/+$/, "");
export const BASE_PATH = "https://api.immutable.com".replace(/\/+$/, "");

/**
*
Expand Down
Loading

0 comments on commit 545c6e7

Please sign in to comment.