@medialane/sdk 0.11.0 → 0.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -348,7 +348,43 @@ declare class Medialane1155Module {
348
348
 
349
349
  type IPType = "Audio" | "Art" | "Documents" | "NFT" | "Video" | "Photography" | "Patents" | "Posts" | "Publications" | "RWA" | "Software" | "Custom";
350
350
  type CollectionSort = "recent" | "supply" | "floor" | "volume" | "name";
351
- type CollectionSource = "MEDIALANE_REGISTRY" | "EXTERNAL" | "PARTNERSHIP" | "IP_TICKET" | "IP_CLUB" | "GAME" | "POP_PROTOCOL" | "COLLECTION_DROP";
351
+ /** Bounded capability set (05-service-model §III). Expand the union when a
352
+ * service needs behavior outside it — never make it free-form. */
353
+ type ServiceCapability = "list" | "buy" | "make_offer" | "cancel" | "transfer" | "burn" | "mint" | "claim" | "airdrop" | "remix" | "license" | "subscribe" | "redeem";
354
+ /** A service that bakes enforcement into its own contract declares it here
355
+ * (04-licensing-model §V, 05-service-model §IV). Absence/all-falsey =
356
+ * soft enforcement (the 00-principles §9 default). */
357
+ interface EnforcementDeclaration {
358
+ royalty?: "erc2981" | "service-split" | "none";
359
+ escrow?: boolean;
360
+ timeLock?: boolean;
361
+ revocable?: boolean;
362
+ }
363
+ /** Declarative description of a service (05-service-model §II).
364
+ * SDK-resident in v1; on-chain registry in year 2. */
365
+ interface ServiceDefinition {
366
+ /** Stable kebab-case id. NO version number (05 §II). */
367
+ id: string;
368
+ displayName: string;
369
+ description: string;
370
+ standard: "ERC721" | "ERC1155" | "UNKNOWN";
371
+ provenance: "MEDIALANE" | "EXTERNAL";
372
+ onchain?: {
373
+ factoryAddress?: string;
374
+ classHash?: string;
375
+ startBlock?: number;
376
+ };
377
+ /** Drives the dapp asset/collection page variant. */
378
+ uiVariant: string;
379
+ capabilities: ServiceCapability[];
380
+ metadataSchema?: {
381
+ requiredTraits?: string[];
382
+ /** Canonical platform default is "CC BY-SA" (04-licensing-model §III). */
383
+ licenseDefault?: string;
384
+ enforcement?: EnforcementDeclaration;
385
+ };
386
+ }
387
+ type CollectionSource = "MEDIALANE_ERC721" | "MEDIALANE_ERC1155" | "EXTERNAL_ERC721" | "EXTERNAL_ERC1155" | "MEDIALANE_REGISTRY" | "ERC1155_FACTORY" | "EXTERNAL" | "PARTNERSHIP" | "IP_TICKET" | "IP_CLUB" | "GAME" | "POP_PROTOCOL" | "COLLECTION_DROP";
352
388
  interface ApiCollectionsQuery {
353
389
  page?: number;
354
390
  limit?: number;
@@ -356,6 +392,8 @@ interface ApiCollectionsQuery {
356
392
  sort?: CollectionSort;
357
393
  owner?: string;
358
394
  source?: CollectionSource;
395
+ /** Filter by service id (preferred over `source`). */
396
+ service?: string;
359
397
  }
360
398
  type OrderStatus = "ACTIVE" | "FULFILLED" | "CANCELLED" | "EXPIRED" | "COUNTER_OFFERED";
361
399
  type SortOrder = "price_asc" | "price_desc" | "recent";
@@ -531,6 +569,10 @@ interface ApiCollection {
531
569
  /** Token standard detected via ERC-165. */
532
570
  standard: "ERC721" | "ERC1155" | "UNKNOWN";
533
571
  isKnown: boolean;
572
+ /** Stable Medialane service ID, or null for external collections.
573
+ * Resolve via getService() (05-service-model). Primary field. */
574
+ service: string | null;
575
+ /** @deprecated Since 0.12.0 — use `service`. Removed in 0.13.0. */
534
576
  source: CollectionSource;
535
577
  claimedBy: string | null;
536
578
  profile?: ApiCollectionProfile | null;
@@ -959,7 +1001,7 @@ declare class ApiClient {
959
1001
  getToken(contract: string, tokenId: string, wait?: boolean): Promise<ApiResponse<ApiToken>>;
960
1002
  getTokensByOwner(address: string, page?: number, limit?: number): Promise<ApiResponse<ApiToken[]>>;
961
1003
  getTokenHistory(contract: string, tokenId: string, page?: number, limit?: number): Promise<ApiResponse<ApiActivity[]>>;
962
- getCollections(page?: number, limit?: number, isKnown?: boolean, sort?: CollectionSort, source?: CollectionSource): Promise<ApiResponse<ApiCollection[]>>;
1004
+ getCollections(page?: number, limit?: number, isKnown?: boolean, sort?: CollectionSort, source?: CollectionSource, service?: string): Promise<ApiResponse<ApiCollection[]>>;
963
1005
  getCollectionsByOwner(owner: string, page?: number, limit?: number): Promise<ApiResponse<ApiCollection[]>>;
964
1006
  getCollection(contract: string): Promise<ApiResponse<ApiCollection>>;
965
1007
  getCollectionTokens(contract: string, page?: number, limit?: number): Promise<ApiResponse<ApiToken[]>>;
@@ -4102,6 +4144,14 @@ declare const IPNftABI: readonly [{
4102
4144
  }];
4103
4145
  }];
4104
4146
 
4147
+ /** Lookup. Returns undefined for external/unknown (service: null) — callers
4148
+ * fall back to standard-based generic UI (01-core-model §I). */
4149
+ declare function getService(id: string | null | undefined): ServiceDefinition | undefined;
4150
+ /** All registered services (e.g. the launchpad grid). */
4151
+ declare function listServices(): ServiceDefinition[];
4152
+ /** Services that declare a capability (e.g. "where can users mint"). */
4153
+ declare function getServicesByCapability(cap: ServiceCapability): ServiceDefinition[];
4154
+
4105
4155
  /**
4106
4156
  * Normalize a Starknet address to a 0x-prefixed 64-character hex string.
4107
4157
  */
@@ -4192,4 +4242,4 @@ declare function build1155FulfillmentTypedData(message: Record<string, unknown>,
4192
4242
  */
4193
4243
  declare function build1155CancellationTypedData(message: Record<string, unknown>, chainId: constants.StarknetChainId): TypedData;
4194
4244
 
4195
- export { type ActivityType, type ApiActivitiesQuery, type ApiActivity, type ApiActivityPrice, type ApiAdminCollectionClaim, ApiClient, type ApiCollection, type ApiCollectionClaim, type ApiCollectionProfile, type ApiCollectionSlugClaim, type ApiCollectionsQuery, type ApiComment, type ApiCounterOffersQuery, type ApiCreatorListResult, type ApiCreatorProfile, type ApiIntent, type ApiIntentCreated, type ApiKeyStatus, type ApiMeta, type ApiMetadataSignedUrl, type ApiMetadataUpload, type ApiOrder, type ApiOrderConsideration, type ApiOrderOffer, type ApiOrderPrice, type ApiOrderTokenMeta, type ApiOrderTxHash, type ApiOrdersQuery, type ApiPortalKey, type ApiPortalKeyCreated, type ApiPortalMe, type ApiPublicRemix, type ApiRemixOffer, type ApiRemixOfferPrice, type ApiRemixOffersQuery, type ApiResponse, type ApiSearchCollectionResult, type ApiSearchCreatorResult, type ApiSearchResult, type ApiSearchTokenResult, type ApiToken, type ApiTokenBalance, type ApiTokenMetadata, type ApiUsageDay, type ApiUserWallet, type ApiWebhookCreated, type ApiWebhookEndpoint, type AutoRemixOfferParams, type BatchMintItemParams, COLLECTION_1155_CLASS_HASH_MAINNET, COLLECTION_1155_CONTRACT_MAINNET, COLLECTION_721_CONTRACT_MAINNET, COLLECTION_CONTRACT_MAINNET, type CancelOrder1155Params, type CancelOrderIntentParams, type CancelOrderParams, type Cancelation, type CartItem, type ClaimConditions, CollectionRegistryABI, type CollectionSort, type CollectionSource, type ConfirmRemixOfferParams, type ConfirmSelfRemixParams, type ConsiderationItem, type CreateCollectionIntentParams, type CreateCollectionParams, type CreateCounterOfferIntentParams, type CreateDropParams, type CreateListing1155Params, type CreateListingIntentParams, type CreateListingParams, type CreateMintIntentParams, type CreatePopCollectionParams, type CreateRemixOfferParams, type CreateWebhookParams, DEFAULT_RPC_URL, DROP_COLLECTION_CLASS_HASH_MAINNET, DROP_FACTORY_CONTRACT_MAINNET, type DeployCollectionParams, DropCollectionABI, DropFactoryABI, type DropMintStatus, DropService, ERC1155CollectionService, ERC1155_COLLECTION_CLASS_HASH_MAINNET, ERC1155_FACTORY_CONTRACT_MAINNET, type FulfillOrder1155Params, type FulfillOrderIntentParams, type FulfillOrderParams, type Fulfillment, INDEXER_START_BLOCK_MAINNET, IPCollection1155ABI, IPCollection1155FactoryABI, IPCollectionABI, IPMarketplaceABI, IPNftABI, type IPType, type IntentStatus, type IntentType, type IpAttribute, type IpNftMetadata, MARKETPLACE_1155_CLASS_HASH_MAINNET, MARKETPLACE_1155_CONTRACT_MAINNET, MARKETPLACE_1155_START_BLOCK_MAINNET, MARKETPLACE_721_CLASS_HASH_MAINNET, MARKETPLACE_721_CONTRACT_MAINNET, MARKETPLACE_721_START_BLOCK_MAINNET, MARKETPLACE_CLASS_HASH_MAINNET, MARKETPLACE_CONTRACT_MAINNET, MARKETPLACE_START_BLOCK_MAINNET, type MakeOffer1155Params, type MakeOfferIntentParams, type MakeOfferParams, MarketplaceModule, Medialane1155ABI, Medialane1155Module, MedialaneApiError, MedialaneClient, type MedialaneConfig, MedialaneError, type MedialaneErrorCode, type MintItemParams, type MintParams, NFTCOMMENTS_CONTRACT_MAINNET, type Network, OPEN_LICENSES, type OfferItem, type OpenLicense, type Order, type OrderDetails, type OrderParameters, type OrderStatus, POPCollectionABI, POPFactoryABI, POP_COLLECTION_CLASS_HASH_MAINNET, POP_FACTORY_CONTRACT_MAINNET, type PopBatchEligibilityItem, type PopClaimStatus, type PopEventType, PopService, type RemixOfferStatus, type ResolvedConfig, type RetryOptions, SUPPORTED_NETWORKS, SUPPORTED_TOKENS, type SortOrder, type SupportedToken, type SupportedTokenSymbol, type TenantPlan, type TxResult, type WebhookEventType, type WebhookStatus, build1155CancellationTypedData, build1155FulfillmentTypedData, build1155OrderTypedData, buildCancellationTypedData, buildFulfillmentTypedData, buildOrderTypedData, encodeByteArray, formatAmount, getListableTokens, getTokenByAddress, getTokenBySymbol, normalizeAddress, parseAmount, resolveConfig, shortenAddress, stringifyBigInts, u256ToBigInt };
4245
+ export { type ActivityType, type ApiActivitiesQuery, type ApiActivity, type ApiActivityPrice, type ApiAdminCollectionClaim, ApiClient, type ApiCollection, type ApiCollectionClaim, type ApiCollectionProfile, type ApiCollectionSlugClaim, type ApiCollectionsQuery, type ApiComment, type ApiCounterOffersQuery, type ApiCreatorListResult, type ApiCreatorProfile, type ApiIntent, type ApiIntentCreated, type ApiKeyStatus, type ApiMeta, type ApiMetadataSignedUrl, type ApiMetadataUpload, type ApiOrder, type ApiOrderConsideration, type ApiOrderOffer, type ApiOrderPrice, type ApiOrderTokenMeta, type ApiOrderTxHash, type ApiOrdersQuery, type ApiPortalKey, type ApiPortalKeyCreated, type ApiPortalMe, type ApiPublicRemix, type ApiRemixOffer, type ApiRemixOfferPrice, type ApiRemixOffersQuery, type ApiResponse, type ApiSearchCollectionResult, type ApiSearchCreatorResult, type ApiSearchResult, type ApiSearchTokenResult, type ApiToken, type ApiTokenBalance, type ApiTokenMetadata, type ApiUsageDay, type ApiUserWallet, type ApiWebhookCreated, type ApiWebhookEndpoint, type AutoRemixOfferParams, type BatchMintItemParams, COLLECTION_1155_CLASS_HASH_MAINNET, COLLECTION_1155_CONTRACT_MAINNET, COLLECTION_721_CONTRACT_MAINNET, COLLECTION_CONTRACT_MAINNET, type CancelOrder1155Params, type CancelOrderIntentParams, type CancelOrderParams, type Cancelation, type CartItem, type ClaimConditions, CollectionRegistryABI, type CollectionSort, type CollectionSource, type ConfirmRemixOfferParams, type ConfirmSelfRemixParams, type ConsiderationItem, type CreateCollectionIntentParams, type CreateCollectionParams, type CreateCounterOfferIntentParams, type CreateDropParams, type CreateListing1155Params, type CreateListingIntentParams, type CreateListingParams, type CreateMintIntentParams, type CreatePopCollectionParams, type CreateRemixOfferParams, type CreateWebhookParams, DEFAULT_RPC_URL, DROP_COLLECTION_CLASS_HASH_MAINNET, DROP_FACTORY_CONTRACT_MAINNET, type DeployCollectionParams, DropCollectionABI, DropFactoryABI, type DropMintStatus, DropService, ERC1155CollectionService, ERC1155_COLLECTION_CLASS_HASH_MAINNET, ERC1155_FACTORY_CONTRACT_MAINNET, type EnforcementDeclaration, type FulfillOrder1155Params, type FulfillOrderIntentParams, type FulfillOrderParams, type Fulfillment, INDEXER_START_BLOCK_MAINNET, IPCollection1155ABI, IPCollection1155FactoryABI, IPCollectionABI, IPMarketplaceABI, IPNftABI, type IPType, type IntentStatus, type IntentType, type IpAttribute, type IpNftMetadata, MARKETPLACE_1155_CLASS_HASH_MAINNET, MARKETPLACE_1155_CONTRACT_MAINNET, MARKETPLACE_1155_START_BLOCK_MAINNET, MARKETPLACE_721_CLASS_HASH_MAINNET, MARKETPLACE_721_CONTRACT_MAINNET, MARKETPLACE_721_START_BLOCK_MAINNET, MARKETPLACE_CLASS_HASH_MAINNET, MARKETPLACE_CONTRACT_MAINNET, MARKETPLACE_START_BLOCK_MAINNET, type MakeOffer1155Params, type MakeOfferIntentParams, type MakeOfferParams, MarketplaceModule, Medialane1155ABI, Medialane1155Module, MedialaneApiError, MedialaneClient, type MedialaneConfig, MedialaneError, type MedialaneErrorCode, type MintItemParams, type MintParams, NFTCOMMENTS_CONTRACT_MAINNET, type Network, OPEN_LICENSES, type OfferItem, type OpenLicense, type Order, type OrderDetails, type OrderParameters, type OrderStatus, POPCollectionABI, POPFactoryABI, POP_COLLECTION_CLASS_HASH_MAINNET, POP_FACTORY_CONTRACT_MAINNET, type PopBatchEligibilityItem, type PopClaimStatus, type PopEventType, PopService, type RemixOfferStatus, type ResolvedConfig, type RetryOptions, SUPPORTED_NETWORKS, SUPPORTED_TOKENS, type ServiceCapability, type ServiceDefinition, type SortOrder, type SupportedToken, type SupportedTokenSymbol, type TenantPlan, type TxResult, type WebhookEventType, type WebhookStatus, build1155CancellationTypedData, build1155FulfillmentTypedData, build1155OrderTypedData, buildCancellationTypedData, buildFulfillmentTypedData, buildOrderTypedData, encodeByteArray, formatAmount, getListableTokens, getService, getServicesByCapability, getTokenByAddress, getTokenBySymbol, listServices, normalizeAddress, parseAmount, resolveConfig, shortenAddress, stringifyBigInts, u256ToBigInt };
package/dist/index.d.ts CHANGED
@@ -348,7 +348,43 @@ declare class Medialane1155Module {
348
348
 
349
349
  type IPType = "Audio" | "Art" | "Documents" | "NFT" | "Video" | "Photography" | "Patents" | "Posts" | "Publications" | "RWA" | "Software" | "Custom";
350
350
  type CollectionSort = "recent" | "supply" | "floor" | "volume" | "name";
351
- type CollectionSource = "MEDIALANE_REGISTRY" | "EXTERNAL" | "PARTNERSHIP" | "IP_TICKET" | "IP_CLUB" | "GAME" | "POP_PROTOCOL" | "COLLECTION_DROP";
351
+ /** Bounded capability set (05-service-model §III). Expand the union when a
352
+ * service needs behavior outside it — never make it free-form. */
353
+ type ServiceCapability = "list" | "buy" | "make_offer" | "cancel" | "transfer" | "burn" | "mint" | "claim" | "airdrop" | "remix" | "license" | "subscribe" | "redeem";
354
+ /** A service that bakes enforcement into its own contract declares it here
355
+ * (04-licensing-model §V, 05-service-model §IV). Absence/all-falsey =
356
+ * soft enforcement (the 00-principles §9 default). */
357
+ interface EnforcementDeclaration {
358
+ royalty?: "erc2981" | "service-split" | "none";
359
+ escrow?: boolean;
360
+ timeLock?: boolean;
361
+ revocable?: boolean;
362
+ }
363
+ /** Declarative description of a service (05-service-model §II).
364
+ * SDK-resident in v1; on-chain registry in year 2. */
365
+ interface ServiceDefinition {
366
+ /** Stable kebab-case id. NO version number (05 §II). */
367
+ id: string;
368
+ displayName: string;
369
+ description: string;
370
+ standard: "ERC721" | "ERC1155" | "UNKNOWN";
371
+ provenance: "MEDIALANE" | "EXTERNAL";
372
+ onchain?: {
373
+ factoryAddress?: string;
374
+ classHash?: string;
375
+ startBlock?: number;
376
+ };
377
+ /** Drives the dapp asset/collection page variant. */
378
+ uiVariant: string;
379
+ capabilities: ServiceCapability[];
380
+ metadataSchema?: {
381
+ requiredTraits?: string[];
382
+ /** Canonical platform default is "CC BY-SA" (04-licensing-model §III). */
383
+ licenseDefault?: string;
384
+ enforcement?: EnforcementDeclaration;
385
+ };
386
+ }
387
+ type CollectionSource = "MEDIALANE_ERC721" | "MEDIALANE_ERC1155" | "EXTERNAL_ERC721" | "EXTERNAL_ERC1155" | "MEDIALANE_REGISTRY" | "ERC1155_FACTORY" | "EXTERNAL" | "PARTNERSHIP" | "IP_TICKET" | "IP_CLUB" | "GAME" | "POP_PROTOCOL" | "COLLECTION_DROP";
352
388
  interface ApiCollectionsQuery {
353
389
  page?: number;
354
390
  limit?: number;
@@ -356,6 +392,8 @@ interface ApiCollectionsQuery {
356
392
  sort?: CollectionSort;
357
393
  owner?: string;
358
394
  source?: CollectionSource;
395
+ /** Filter by service id (preferred over `source`). */
396
+ service?: string;
359
397
  }
360
398
  type OrderStatus = "ACTIVE" | "FULFILLED" | "CANCELLED" | "EXPIRED" | "COUNTER_OFFERED";
361
399
  type SortOrder = "price_asc" | "price_desc" | "recent";
@@ -531,6 +569,10 @@ interface ApiCollection {
531
569
  /** Token standard detected via ERC-165. */
532
570
  standard: "ERC721" | "ERC1155" | "UNKNOWN";
533
571
  isKnown: boolean;
572
+ /** Stable Medialane service ID, or null for external collections.
573
+ * Resolve via getService() (05-service-model). Primary field. */
574
+ service: string | null;
575
+ /** @deprecated Since 0.12.0 — use `service`. Removed in 0.13.0. */
534
576
  source: CollectionSource;
535
577
  claimedBy: string | null;
536
578
  profile?: ApiCollectionProfile | null;
@@ -959,7 +1001,7 @@ declare class ApiClient {
959
1001
  getToken(contract: string, tokenId: string, wait?: boolean): Promise<ApiResponse<ApiToken>>;
960
1002
  getTokensByOwner(address: string, page?: number, limit?: number): Promise<ApiResponse<ApiToken[]>>;
961
1003
  getTokenHistory(contract: string, tokenId: string, page?: number, limit?: number): Promise<ApiResponse<ApiActivity[]>>;
962
- getCollections(page?: number, limit?: number, isKnown?: boolean, sort?: CollectionSort, source?: CollectionSource): Promise<ApiResponse<ApiCollection[]>>;
1004
+ getCollections(page?: number, limit?: number, isKnown?: boolean, sort?: CollectionSort, source?: CollectionSource, service?: string): Promise<ApiResponse<ApiCollection[]>>;
963
1005
  getCollectionsByOwner(owner: string, page?: number, limit?: number): Promise<ApiResponse<ApiCollection[]>>;
964
1006
  getCollection(contract: string): Promise<ApiResponse<ApiCollection>>;
965
1007
  getCollectionTokens(contract: string, page?: number, limit?: number): Promise<ApiResponse<ApiToken[]>>;
@@ -4102,6 +4144,14 @@ declare const IPNftABI: readonly [{
4102
4144
  }];
4103
4145
  }];
4104
4146
 
4147
+ /** Lookup. Returns undefined for external/unknown (service: null) — callers
4148
+ * fall back to standard-based generic UI (01-core-model §I). */
4149
+ declare function getService(id: string | null | undefined): ServiceDefinition | undefined;
4150
+ /** All registered services (e.g. the launchpad grid). */
4151
+ declare function listServices(): ServiceDefinition[];
4152
+ /** Services that declare a capability (e.g. "where can users mint"). */
4153
+ declare function getServicesByCapability(cap: ServiceCapability): ServiceDefinition[];
4154
+
4105
4155
  /**
4106
4156
  * Normalize a Starknet address to a 0x-prefixed 64-character hex string.
4107
4157
  */
@@ -4192,4 +4242,4 @@ declare function build1155FulfillmentTypedData(message: Record<string, unknown>,
4192
4242
  */
4193
4243
  declare function build1155CancellationTypedData(message: Record<string, unknown>, chainId: constants.StarknetChainId): TypedData;
4194
4244
 
4195
- export { type ActivityType, type ApiActivitiesQuery, type ApiActivity, type ApiActivityPrice, type ApiAdminCollectionClaim, ApiClient, type ApiCollection, type ApiCollectionClaim, type ApiCollectionProfile, type ApiCollectionSlugClaim, type ApiCollectionsQuery, type ApiComment, type ApiCounterOffersQuery, type ApiCreatorListResult, type ApiCreatorProfile, type ApiIntent, type ApiIntentCreated, type ApiKeyStatus, type ApiMeta, type ApiMetadataSignedUrl, type ApiMetadataUpload, type ApiOrder, type ApiOrderConsideration, type ApiOrderOffer, type ApiOrderPrice, type ApiOrderTokenMeta, type ApiOrderTxHash, type ApiOrdersQuery, type ApiPortalKey, type ApiPortalKeyCreated, type ApiPortalMe, type ApiPublicRemix, type ApiRemixOffer, type ApiRemixOfferPrice, type ApiRemixOffersQuery, type ApiResponse, type ApiSearchCollectionResult, type ApiSearchCreatorResult, type ApiSearchResult, type ApiSearchTokenResult, type ApiToken, type ApiTokenBalance, type ApiTokenMetadata, type ApiUsageDay, type ApiUserWallet, type ApiWebhookCreated, type ApiWebhookEndpoint, type AutoRemixOfferParams, type BatchMintItemParams, COLLECTION_1155_CLASS_HASH_MAINNET, COLLECTION_1155_CONTRACT_MAINNET, COLLECTION_721_CONTRACT_MAINNET, COLLECTION_CONTRACT_MAINNET, type CancelOrder1155Params, type CancelOrderIntentParams, type CancelOrderParams, type Cancelation, type CartItem, type ClaimConditions, CollectionRegistryABI, type CollectionSort, type CollectionSource, type ConfirmRemixOfferParams, type ConfirmSelfRemixParams, type ConsiderationItem, type CreateCollectionIntentParams, type CreateCollectionParams, type CreateCounterOfferIntentParams, type CreateDropParams, type CreateListing1155Params, type CreateListingIntentParams, type CreateListingParams, type CreateMintIntentParams, type CreatePopCollectionParams, type CreateRemixOfferParams, type CreateWebhookParams, DEFAULT_RPC_URL, DROP_COLLECTION_CLASS_HASH_MAINNET, DROP_FACTORY_CONTRACT_MAINNET, type DeployCollectionParams, DropCollectionABI, DropFactoryABI, type DropMintStatus, DropService, ERC1155CollectionService, ERC1155_COLLECTION_CLASS_HASH_MAINNET, ERC1155_FACTORY_CONTRACT_MAINNET, type FulfillOrder1155Params, type FulfillOrderIntentParams, type FulfillOrderParams, type Fulfillment, INDEXER_START_BLOCK_MAINNET, IPCollection1155ABI, IPCollection1155FactoryABI, IPCollectionABI, IPMarketplaceABI, IPNftABI, type IPType, type IntentStatus, type IntentType, type IpAttribute, type IpNftMetadata, MARKETPLACE_1155_CLASS_HASH_MAINNET, MARKETPLACE_1155_CONTRACT_MAINNET, MARKETPLACE_1155_START_BLOCK_MAINNET, MARKETPLACE_721_CLASS_HASH_MAINNET, MARKETPLACE_721_CONTRACT_MAINNET, MARKETPLACE_721_START_BLOCK_MAINNET, MARKETPLACE_CLASS_HASH_MAINNET, MARKETPLACE_CONTRACT_MAINNET, MARKETPLACE_START_BLOCK_MAINNET, type MakeOffer1155Params, type MakeOfferIntentParams, type MakeOfferParams, MarketplaceModule, Medialane1155ABI, Medialane1155Module, MedialaneApiError, MedialaneClient, type MedialaneConfig, MedialaneError, type MedialaneErrorCode, type MintItemParams, type MintParams, NFTCOMMENTS_CONTRACT_MAINNET, type Network, OPEN_LICENSES, type OfferItem, type OpenLicense, type Order, type OrderDetails, type OrderParameters, type OrderStatus, POPCollectionABI, POPFactoryABI, POP_COLLECTION_CLASS_HASH_MAINNET, POP_FACTORY_CONTRACT_MAINNET, type PopBatchEligibilityItem, type PopClaimStatus, type PopEventType, PopService, type RemixOfferStatus, type ResolvedConfig, type RetryOptions, SUPPORTED_NETWORKS, SUPPORTED_TOKENS, type SortOrder, type SupportedToken, type SupportedTokenSymbol, type TenantPlan, type TxResult, type WebhookEventType, type WebhookStatus, build1155CancellationTypedData, build1155FulfillmentTypedData, build1155OrderTypedData, buildCancellationTypedData, buildFulfillmentTypedData, buildOrderTypedData, encodeByteArray, formatAmount, getListableTokens, getTokenByAddress, getTokenBySymbol, normalizeAddress, parseAmount, resolveConfig, shortenAddress, stringifyBigInts, u256ToBigInt };
4245
+ export { type ActivityType, type ApiActivitiesQuery, type ApiActivity, type ApiActivityPrice, type ApiAdminCollectionClaim, ApiClient, type ApiCollection, type ApiCollectionClaim, type ApiCollectionProfile, type ApiCollectionSlugClaim, type ApiCollectionsQuery, type ApiComment, type ApiCounterOffersQuery, type ApiCreatorListResult, type ApiCreatorProfile, type ApiIntent, type ApiIntentCreated, type ApiKeyStatus, type ApiMeta, type ApiMetadataSignedUrl, type ApiMetadataUpload, type ApiOrder, type ApiOrderConsideration, type ApiOrderOffer, type ApiOrderPrice, type ApiOrderTokenMeta, type ApiOrderTxHash, type ApiOrdersQuery, type ApiPortalKey, type ApiPortalKeyCreated, type ApiPortalMe, type ApiPublicRemix, type ApiRemixOffer, type ApiRemixOfferPrice, type ApiRemixOffersQuery, type ApiResponse, type ApiSearchCollectionResult, type ApiSearchCreatorResult, type ApiSearchResult, type ApiSearchTokenResult, type ApiToken, type ApiTokenBalance, type ApiTokenMetadata, type ApiUsageDay, type ApiUserWallet, type ApiWebhookCreated, type ApiWebhookEndpoint, type AutoRemixOfferParams, type BatchMintItemParams, COLLECTION_1155_CLASS_HASH_MAINNET, COLLECTION_1155_CONTRACT_MAINNET, COLLECTION_721_CONTRACT_MAINNET, COLLECTION_CONTRACT_MAINNET, type CancelOrder1155Params, type CancelOrderIntentParams, type CancelOrderParams, type Cancelation, type CartItem, type ClaimConditions, CollectionRegistryABI, type CollectionSort, type CollectionSource, type ConfirmRemixOfferParams, type ConfirmSelfRemixParams, type ConsiderationItem, type CreateCollectionIntentParams, type CreateCollectionParams, type CreateCounterOfferIntentParams, type CreateDropParams, type CreateListing1155Params, type CreateListingIntentParams, type CreateListingParams, type CreateMintIntentParams, type CreatePopCollectionParams, type CreateRemixOfferParams, type CreateWebhookParams, DEFAULT_RPC_URL, DROP_COLLECTION_CLASS_HASH_MAINNET, DROP_FACTORY_CONTRACT_MAINNET, type DeployCollectionParams, DropCollectionABI, DropFactoryABI, type DropMintStatus, DropService, ERC1155CollectionService, ERC1155_COLLECTION_CLASS_HASH_MAINNET, ERC1155_FACTORY_CONTRACT_MAINNET, type EnforcementDeclaration, type FulfillOrder1155Params, type FulfillOrderIntentParams, type FulfillOrderParams, type Fulfillment, INDEXER_START_BLOCK_MAINNET, IPCollection1155ABI, IPCollection1155FactoryABI, IPCollectionABI, IPMarketplaceABI, IPNftABI, type IPType, type IntentStatus, type IntentType, type IpAttribute, type IpNftMetadata, MARKETPLACE_1155_CLASS_HASH_MAINNET, MARKETPLACE_1155_CONTRACT_MAINNET, MARKETPLACE_1155_START_BLOCK_MAINNET, MARKETPLACE_721_CLASS_HASH_MAINNET, MARKETPLACE_721_CONTRACT_MAINNET, MARKETPLACE_721_START_BLOCK_MAINNET, MARKETPLACE_CLASS_HASH_MAINNET, MARKETPLACE_CONTRACT_MAINNET, MARKETPLACE_START_BLOCK_MAINNET, type MakeOffer1155Params, type MakeOfferIntentParams, type MakeOfferParams, MarketplaceModule, Medialane1155ABI, Medialane1155Module, MedialaneApiError, MedialaneClient, type MedialaneConfig, MedialaneError, type MedialaneErrorCode, type MintItemParams, type MintParams, NFTCOMMENTS_CONTRACT_MAINNET, type Network, OPEN_LICENSES, type OfferItem, type OpenLicense, type Order, type OrderDetails, type OrderParameters, type OrderStatus, POPCollectionABI, POPFactoryABI, POP_COLLECTION_CLASS_HASH_MAINNET, POP_FACTORY_CONTRACT_MAINNET, type PopBatchEligibilityItem, type PopClaimStatus, type PopEventType, PopService, type RemixOfferStatus, type ResolvedConfig, type RetryOptions, SUPPORTED_NETWORKS, SUPPORTED_TOKENS, type ServiceCapability, type ServiceDefinition, type SortOrder, type SupportedToken, type SupportedTokenSymbol, type TenantPlan, type TxResult, type WebhookEventType, type WebhookStatus, build1155CancellationTypedData, build1155FulfillmentTypedData, build1155OrderTypedData, buildCancellationTypedData, buildFulfillmentTypedData, buildOrderTypedData, encodeByteArray, formatAmount, getListableTokens, getService, getServicesByCapability, getTokenByAddress, getTokenBySymbol, listServices, normalizeAddress, parseAmount, resolveConfig, shortenAddress, stringifyBigInts, u256ToBigInt };
package/dist/index.js CHANGED
@@ -4324,11 +4324,12 @@ var ApiClient = class {
4324
4324
  );
4325
4325
  }
4326
4326
  // ─── Collections ───────────────────────────────────────────────────────────
4327
- getCollections(page = 1, limit = 20, isKnown, sort, source) {
4327
+ getCollections(page = 1, limit = 20, isKnown, sort, source, service) {
4328
4328
  const params = new URLSearchParams({ page: String(page), limit: String(limit) });
4329
4329
  if (isKnown !== void 0) params.set("isKnown", String(isKnown));
4330
4330
  if (sort) params.set("sort", sort);
4331
4331
  if (source) params.set("source", source);
4332
+ if (service) params.set("service", service);
4332
4333
  return this.get(`/v1/collections?${params}`);
4333
4334
  }
4334
4335
  getCollectionsByOwner(owner, page = 1, limit = 50) {
@@ -5051,6 +5052,114 @@ var MedialaneClient = class {
5051
5052
  // src/types/api.ts
5052
5053
  var OPEN_LICENSES = ["CC0", "CC BY", "CC BY-SA", "CC BY-NC"];
5053
5054
 
5054
- export { ApiClient, COLLECTION_1155_CLASS_HASH_MAINNET, COLLECTION_1155_CONTRACT_MAINNET, COLLECTION_721_CONTRACT_MAINNET, COLLECTION_CONTRACT_MAINNET, CollectionRegistryABI, DEFAULT_RPC_URL, DROP_COLLECTION_CLASS_HASH_MAINNET, DROP_FACTORY_CONTRACT_MAINNET, DropCollectionABI, DropFactoryABI, DropService, ERC1155CollectionService, ERC1155_COLLECTION_CLASS_HASH_MAINNET, ERC1155_FACTORY_CONTRACT_MAINNET, INDEXER_START_BLOCK_MAINNET, IPCollection1155ABI, IPCollection1155FactoryABI, IPCollectionABI, IPMarketplaceABI, IPNftABI, MARKETPLACE_1155_CLASS_HASH_MAINNET, MARKETPLACE_1155_CONTRACT_MAINNET, MARKETPLACE_1155_START_BLOCK_MAINNET, MARKETPLACE_721_CLASS_HASH_MAINNET, MARKETPLACE_721_CONTRACT_MAINNET, MARKETPLACE_721_START_BLOCK_MAINNET, MARKETPLACE_CLASS_HASH_MAINNET, MARKETPLACE_CONTRACT_MAINNET, MARKETPLACE_START_BLOCK_MAINNET, MarketplaceModule, Medialane1155ABI, Medialane1155Module, MedialaneApiError, MedialaneClient, MedialaneError, NFTCOMMENTS_CONTRACT_MAINNET, OPEN_LICENSES, POPCollectionABI, POPFactoryABI, POP_COLLECTION_CLASS_HASH_MAINNET, POP_FACTORY_CONTRACT_MAINNET, PopService, SUPPORTED_NETWORKS, SUPPORTED_TOKENS, build1155CancellationTypedData, build1155FulfillmentTypedData, build1155OrderTypedData, buildCancellationTypedData, buildFulfillmentTypedData, buildOrderTypedData, encodeByteArray, formatAmount, getListableTokens, getTokenByAddress, getTokenBySymbol, normalizeAddress, parseAmount, resolveConfig, shortenAddress, stringifyBigInts, u256ToBigInt };
5055
+ // src/services/registry.ts
5056
+ var SERVICES = {
5057
+ "mip-erc721": {
5058
+ id: "mip-erc721",
5059
+ displayName: "IP Collection",
5060
+ description: "Tokenize intellectual property as a per-creator ERC-721 collection.",
5061
+ standard: "ERC721",
5062
+ provenance: "MEDIALANE",
5063
+ onchain: {
5064
+ factoryAddress: COLLECTION_721_CONTRACT_MAINNET,
5065
+ startBlock: INDEXER_START_BLOCK_MAINNET
5066
+ },
5067
+ uiVariant: "standard",
5068
+ capabilities: ["list", "buy", "make_offer", "cancel", "transfer", "mint", "remix", "license"],
5069
+ metadataSchema: { licenseDefault: "CC BY-SA" }
5070
+ },
5071
+ "ip-erc721": {
5072
+ id: "ip-erc721",
5073
+ displayName: "Programmable IP (genesis)",
5074
+ description: "One shared ERC-721 contract; many wallets mint genesis pieces.",
5075
+ standard: "ERC721",
5076
+ provenance: "MEDIALANE",
5077
+ uiVariant: "standard",
5078
+ capabilities: ["list", "buy", "make_offer", "cancel", "transfer", "mint", "remix", "license"],
5079
+ metadataSchema: { licenseDefault: "CC BY-SA" }
5080
+ },
5081
+ "mip-erc1155": {
5082
+ id: "mip-erc1155",
5083
+ displayName: "NFT Editions",
5084
+ description: "Per-creator ERC-1155 collection; creator mints editions.",
5085
+ standard: "ERC1155",
5086
+ provenance: "MEDIALANE",
5087
+ onchain: {
5088
+ factoryAddress: ERC1155_FACTORY_CONTRACT_MAINNET,
5089
+ classHash: ERC1155_COLLECTION_CLASS_HASH_MAINNET,
5090
+ startBlock: MARKETPLACE_1155_START_BLOCK_MAINNET
5091
+ },
5092
+ uiVariant: "edition",
5093
+ capabilities: ["list", "buy", "make_offer", "cancel", "transfer", "mint", "remix", "license"],
5094
+ metadataSchema: { licenseDefault: "CC BY-SA" }
5095
+ },
5096
+ "pop-protocol": {
5097
+ id: "pop-protocol",
5098
+ displayName: "POP Protocol",
5099
+ description: "Soulbound proof-of-presence collectibles per event.",
5100
+ standard: "ERC721",
5101
+ provenance: "MEDIALANE",
5102
+ onchain: {
5103
+ factoryAddress: POP_FACTORY_CONTRACT_MAINNET,
5104
+ classHash: POP_COLLECTION_CLASS_HASH_MAINNET
5105
+ },
5106
+ uiVariant: "pop",
5107
+ capabilities: ["claim", "transfer"],
5108
+ metadataSchema: { licenseDefault: "CC BY-SA" }
5109
+ },
5110
+ "drop-collection": {
5111
+ id: "drop-collection",
5112
+ displayName: "Collection Drop",
5113
+ description: "Sequential mint with claim windows + allowlist.",
5114
+ standard: "ERC721",
5115
+ provenance: "MEDIALANE",
5116
+ onchain: {
5117
+ factoryAddress: DROP_FACTORY_CONTRACT_MAINNET,
5118
+ classHash: DROP_COLLECTION_CLASS_HASH_MAINNET
5119
+ },
5120
+ uiVariant: "drop",
5121
+ capabilities: ["claim", "list", "buy", "make_offer", "cancel", "transfer"],
5122
+ metadataSchema: { licenseDefault: "CC BY-SA" }
5123
+ },
5124
+ "medialane-marketplace-erc721": {
5125
+ id: "medialane-marketplace-erc721",
5126
+ displayName: "Medialane Marketplace (ERC-721)",
5127
+ description: "ERC-721 order matching venue.",
5128
+ standard: "ERC721",
5129
+ provenance: "MEDIALANE",
5130
+ onchain: {
5131
+ factoryAddress: MARKETPLACE_721_CONTRACT_MAINNET,
5132
+ classHash: MARKETPLACE_721_CLASS_HASH_MAINNET,
5133
+ startBlock: MARKETPLACE_721_START_BLOCK_MAINNET
5134
+ },
5135
+ uiVariant: "standard",
5136
+ capabilities: ["list", "buy", "make_offer", "cancel"]
5137
+ },
5138
+ "medialane-marketplace-erc1155": {
5139
+ id: "medialane-marketplace-erc1155",
5140
+ displayName: "Medialane Marketplace (ERC-1155)",
5141
+ description: "ERC-1155 order matching venue.",
5142
+ standard: "ERC1155",
5143
+ provenance: "MEDIALANE",
5144
+ onchain: {
5145
+ factoryAddress: MARKETPLACE_1155_CONTRACT_MAINNET,
5146
+ classHash: MARKETPLACE_1155_CLASS_HASH_MAINNET,
5147
+ startBlock: MARKETPLACE_1155_START_BLOCK_MAINNET
5148
+ },
5149
+ uiVariant: "edition",
5150
+ capabilities: ["list", "buy", "make_offer", "cancel"]
5151
+ }
5152
+ };
5153
+ function getService(id) {
5154
+ return id ? SERVICES[id] : void 0;
5155
+ }
5156
+ function listServices() {
5157
+ return Object.values(SERVICES);
5158
+ }
5159
+ function getServicesByCapability(cap) {
5160
+ return Object.values(SERVICES).filter((s) => s.capabilities.includes(cap));
5161
+ }
5162
+
5163
+ export { ApiClient, COLLECTION_1155_CLASS_HASH_MAINNET, COLLECTION_1155_CONTRACT_MAINNET, COLLECTION_721_CONTRACT_MAINNET, COLLECTION_CONTRACT_MAINNET, CollectionRegistryABI, DEFAULT_RPC_URL, DROP_COLLECTION_CLASS_HASH_MAINNET, DROP_FACTORY_CONTRACT_MAINNET, DropCollectionABI, DropFactoryABI, DropService, ERC1155CollectionService, ERC1155_COLLECTION_CLASS_HASH_MAINNET, ERC1155_FACTORY_CONTRACT_MAINNET, INDEXER_START_BLOCK_MAINNET, IPCollection1155ABI, IPCollection1155FactoryABI, IPCollectionABI, IPMarketplaceABI, IPNftABI, MARKETPLACE_1155_CLASS_HASH_MAINNET, MARKETPLACE_1155_CONTRACT_MAINNET, MARKETPLACE_1155_START_BLOCK_MAINNET, MARKETPLACE_721_CLASS_HASH_MAINNET, MARKETPLACE_721_CONTRACT_MAINNET, MARKETPLACE_721_START_BLOCK_MAINNET, MARKETPLACE_CLASS_HASH_MAINNET, MARKETPLACE_CONTRACT_MAINNET, MARKETPLACE_START_BLOCK_MAINNET, MarketplaceModule, Medialane1155ABI, Medialane1155Module, MedialaneApiError, MedialaneClient, MedialaneError, NFTCOMMENTS_CONTRACT_MAINNET, OPEN_LICENSES, POPCollectionABI, POPFactoryABI, POP_COLLECTION_CLASS_HASH_MAINNET, POP_FACTORY_CONTRACT_MAINNET, PopService, SUPPORTED_NETWORKS, SUPPORTED_TOKENS, build1155CancellationTypedData, build1155FulfillmentTypedData, build1155OrderTypedData, buildCancellationTypedData, buildFulfillmentTypedData, buildOrderTypedData, encodeByteArray, formatAmount, getListableTokens, getService, getServicesByCapability, getTokenByAddress, getTokenBySymbol, listServices, normalizeAddress, parseAmount, resolveConfig, shortenAddress, stringifyBigInts, u256ToBigInt };
5055
5164
  //# sourceMappingURL=index.js.map
5056
5165
  //# sourceMappingURL=index.js.map