Skip to content

Commit

Permalink
refactor: Regenerate internal NFT refresh types (#1491)
Browse files Browse the repository at this point in the history
  • Loading branch information
allan-almeida-imtbl authored Feb 16, 2024
1 parent 33e8bc4 commit e8286f0
Show file tree
Hide file tree
Showing 13 changed files with 197 additions and 109 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ models/nft.ts
models/nftcontract-type.ts
models/nftmetadata-attribute-value.ts
models/nftmetadata-attribute.ts
models/nftmetadata-request.ts
models/nftowner.ts
models/nftsale.ts
models/nftwith-balance.ts
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,12 @@ export interface GetMintRequestResult {
* @memberof GetMintRequestResult
*/
'token_id': string | null;
/**
* The id of the mint activity associated with this mint request
* @type {string}
* @memberof GetMintRequestResult
*/
'activity_id'?: string | null;
/**
* The transaction hash of the activity
* @type {string}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ export * from './nft';
export * from './nftcontract-type';
export * from './nftmetadata-attribute';
export * from './nftmetadata-attribute-value';
export * from './nftmetadata-request';
export * from './nftowner';
export * from './nftsale';
export * from './nftwith-balance';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

// May contain unused imports in some cases
// @ts-ignore
import { RefreshableNFTAttributes } from './refreshable-nftattributes';
import { NFTMetadataRequest } from './nftmetadata-request';

/**
*
Expand All @@ -37,9 +37,9 @@ export interface MintAsset {
'owner_address': string;
/**
*
* @type {RefreshableNFTAttributes}
* @type {NFTMetadataRequest}
* @memberof MintAsset
*/
'metadata'?: RefreshableNFTAttributes;
'metadata'?: NFTMetadataRequest;
}

Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
/* tslint:disable */
/* eslint-disable */
/**
* Immutable zkEVM API
* Immutable Multi Rollup API
*
* The version of the OpenAPI document: 1.0.0
* Contact: [email protected]
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/


// May contain unused imports in some cases
// @ts-ignore
import { NFTMetadataAttribute } from './nftmetadata-attribute';

/**
*
* @export
* @interface NFTMetadataRequest
*/
export interface NFTMetadataRequest {
/**
* The name of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'name'?: string | null;
/**
* The description of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'description'?: string | null;
/**
* The image url of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'image'?: string | null;
/**
* The external link of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'external_url'?: string | null;
/**
* The animation url of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'animation_url'?: string | null;
/**
* The youtube link of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'youtube_url'?: string | null;
/**
* List of Metadata attributes
* @type {Array<NFTMetadataAttribute>}
* @memberof NFTMetadataRequest
*/
'attributes'?: Array<NFTMetadataAttribute> | null;
}

Original file line number Diff line number Diff line change
Expand Up @@ -16,54 +16,14 @@
// May contain unused imports in some cases
// @ts-ignore
import { NFTMetadataAttribute } from './nftmetadata-attribute';
// May contain unused imports in some cases
// @ts-ignore
import { NFTMetadataRequest } from './nftmetadata-request';

/**
*
* @type RefreshableNFTAttributes
* @export
* @interface RefreshableNFTAttributes
*/
export interface RefreshableNFTAttributes {
/**
* The name of the NFT
* @type {string}
* @memberof RefreshableNFTAttributes
*/
'name': string | null;
/**
* The description of the NFT
* @type {string}
* @memberof RefreshableNFTAttributes
*/
'description': string | null;
/**
* The image url of the NFT
* @type {string}
* @memberof RefreshableNFTAttributes
*/
'image': string | null;
/**
* The external link of the NFT
* @type {string}
* @memberof RefreshableNFTAttributes
*/
'external_url': string | null;
/**
* The animation url of the NFT
* @type {string}
* @memberof RefreshableNFTAttributes
*/
'animation_url': string | null;
/**
* The youtube link of the NFT
* @type {string}
* @memberof RefreshableNFTAttributes
*/
'youtube_url': string | null;
/**
* List of Metadata attributes
* @type {Array<NFTMetadataAttribute>}
* @memberof RefreshableNFTAttributes
*/
'attributes': Array<NFTMetadataAttribute> | null;
}
export type RefreshableNFTAttributes = NFTMetadataRequest;


36 changes: 25 additions & 11 deletions packages/internal/generated-clients/src/mr-openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -4559,6 +4559,22 @@
]
},
"RefreshableNFTAttributes": {
"allOf": [
{
"$ref": "#/components/schemas/NFTMetadataRequest"
}
],
"required": [
"name",
"description",
"image",
"external_url",
"animation_url",
"youtube_url",
"attributes"
]
},
"NFTMetadataRequest": {
"type": "object",
"properties": {
"name": {
Expand Down Expand Up @@ -4605,16 +4621,7 @@
"$ref": "#/components/schemas/NFTMetadataAttribute"
}
}
},
"required": [
"name",
"description",
"image",
"external_url",
"animation_url",
"youtube_url",
"attributes"
]
}
},
"RefreshNFTMetadataByTokenIDRequest": {
"type": "object",
Expand Down Expand Up @@ -4815,7 +4822,7 @@
"example": "0xc344c05eef8876e517072f879dae8905aa2b956b"
},
"metadata": {
"$ref": "#/components/schemas/RefreshableNFTAttributes"
"$ref": "#/components/schemas/NFTMetadataRequest"
}
},
"required": [
Expand Down Expand Up @@ -4848,6 +4855,13 @@
"nullable": true,
"description": "An `uint256` token id as string. Only available when the mint request succeeds"
},
"activity_id": {
"type": "string",
"format": "uuid",
"example": "4e28df8d-f65c-4c11-ba04-6a9dd47b179b",
"nullable": true,
"description": "The id of the mint activity associated with this mint request"
},
"transaction_hash": {
"type": "string",
"nullable": true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ models/nft.ts
models/nftcontract-type.ts
models/nftmetadata-attribute-value.ts
models/nftmetadata-attribute.ts
models/nftmetadata-request.ts
models/nftowner.ts
models/nftsale.ts
models/nftwith-balance.ts
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,12 @@ export interface GetMintRequestResult {
* @memberof GetMintRequestResult
*/
'token_id': string | null;
/**
* The id of the mint activity associated with this mint request
* @type {string}
* @memberof GetMintRequestResult
*/
'activity_id'?: string | null;
/**
* The transaction hash of the activity
* @type {string}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ export * from './nft';
export * from './nftcontract-type';
export * from './nftmetadata-attribute';
export * from './nftmetadata-attribute-value';
export * from './nftmetadata-request';
export * from './nftowner';
export * from './nftsale';
export * from './nftwith-balance';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

// May contain unused imports in some cases
// @ts-ignore
import { RefreshableNFTAttributes } from './refreshable-nftattributes';
import { NFTMetadataRequest } from './nftmetadata-request';

/**
*
Expand All @@ -37,9 +37,9 @@ export interface MintAsset {
'owner_address': string;
/**
*
* @type {RefreshableNFTAttributes}
* @type {NFTMetadataRequest}
* @memberof MintAsset
*/
'metadata'?: RefreshableNFTAttributes;
'metadata'?: NFTMetadataRequest;
}

Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
/* tslint:disable */
/* eslint-disable */
/**
* Immutable zkEVM API
* Immutable Multi Rollup API
*
* The version of the OpenAPI document: 1.0.0
* Contact: [email protected]
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/


// May contain unused imports in some cases
// @ts-ignore
import { NFTMetadataAttribute } from './nftmetadata-attribute';

/**
*
* @export
* @interface NFTMetadataRequest
*/
export interface NFTMetadataRequest {
/**
* The name of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'name'?: string | null;
/**
* The description of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'description'?: string | null;
/**
* The image url of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'image'?: string | null;
/**
* The external link of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'external_url'?: string | null;
/**
* The animation url of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'animation_url'?: string | null;
/**
* The youtube link of the NFT
* @type {string}
* @memberof NFTMetadataRequest
*/
'youtube_url'?: string | null;
/**
* List of Metadata attributes
* @type {Array<NFTMetadataAttribute>}
* @memberof NFTMetadataRequest
*/
'attributes'?: Array<NFTMetadataAttribute> | null;
}

Loading

0 comments on commit e8286f0

Please sign in to comment.