@medialane/sdk 0.95.0 → 0.97.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.
@@ -199,6 +199,7 @@ interface ApiMeta {
199
199
  page: number;
200
200
  limit: number;
201
201
  total?: number;
202
+ counts?: Record<string, number>;
202
203
  }
203
204
  interface ApiResponse<T> {
204
205
  data: T;
@@ -373,6 +374,13 @@ interface ApiCoinPrice {
373
374
  usdc: number;
374
375
  }
375
376
  type ApiCoinPrices = Record<string, ApiCoinPrice | null>;
377
+ type ApiCoinClaimResult = {
378
+ verified: true;
379
+ coin: ApiCoin | null;
380
+ } | {
381
+ verified: false;
382
+ reason: "owner_mismatch" | "owner_check_failed" | "not_erc20" | "no_total_supply";
383
+ };
376
384
  interface ApiCoinsQuery {
377
385
  chain?: ChainFilter;
378
386
  page?: number;
@@ -1163,6 +1171,8 @@ declare class ApiClient {
1163
1171
  data: ApiCoin;
1164
1172
  }>;
1165
1173
  getCoinPrices(): Promise<ApiResponse<ApiCoinPrices>>;
1174
+ claimCoin(coinAddress: string, siwsToken: string): Promise<ApiCoinClaimResult>;
1175
+ getCoinClaims(status?: string): Promise<ApiResponse<ApiCollectionClaim[]>>;
1166
1176
  updateCoinProfile(contract: string, data: {
1167
1177
  image?: string;
1168
1178
  description?: string;
@@ -1291,4 +1301,4 @@ interface ProposeSponsorshipParams {
1291
1301
  royaltyBps: bigint | string;
1292
1302
  }
1293
1303
 
1294
- export { type ApiRewardsLeaderboardEntry as $, type AcceptSponsorshipBidIntentParams as A, type ApiIntentCreated as B, type ApiKeyStatus as C, type ApiMeta as D, type ApiMetadataSignedUrl as E, type ApiMetadataUpload as F, type ApiOrder as G, type ApiOrderConsideration as H, type ApiOrderOffer as I, type ApiOrderPrice as J, type ApiOrderTokenMeta as K, type ApiOrderTxHash as L, type ApiOrdersQuery as M, type ApiPointEvent as N, type ApiPortalKey as O, type ApiPortalKeyCreated as P, type ApiPortalMe as Q, type ResolvedFeeConfig as R, type ServiceDefinition as S, type ApiPublicRemix as T, type ApiRemixOffer as U, type ApiRemixOfferPrice as V, type ApiRemixOffersQuery as W, type ApiResponse as X, type ApiRewardsBadge as Y, type ApiRewardsBatchEntry as Z, type ApiRewardsConfig as _, type ServiceCapability as a, type Order as a$, type ApiRewardsLevel as a0, type ApiSearchCollectionResult as a1, type ApiSearchCreatorResult as a2, type ApiSearchResult as a3, type ApiSearchTokenResult as a4, type ApiToken as a5, type ApiTokenBalance as a6, type ApiTokenMetadata as a7, type ApiUsageDay as a8, type ApiUserRewards as a9, type CreateSponsorshipOfferParams as aA, type CreateSponsorshipProposalIntentParams as aB, type CreateTicketParams as aC, type CreateTierIntentParams as aD, type CreateWebhookParams as aE, type DropMintStatus as aF, type EnforcementDeclaration as aG, type FactoryFamilyServiceId as aH, type FeeConfig as aI, FeeConfigSchema as aJ, type FulfillOrderIntentParams as aK, type IPType as aL, type IntentCall as aM, type IntentStatus as aN, type IntentType as aO, type IpAttribute as aP, type IpNftMetadata as aQ, type LaunchCoinIntentParams as aR, type MakeOfferIntentParams as aS, MedialaneApiError as aT, type MedialaneConfig as aU, type MedialaneErrorCode as aV, type MintMembershipsParams as aW, type MintTicketsParams as aX, OPEN_LICENSES as aY, type OfferItem as aZ, type OpenLicense as a_, type ApiUserWallet as aa, type ApiWalletActivity as ab, type ApiWebhookCreated as ac, type ApiWebhookEndpoint as ad, type AutoRemixOfferParams as ae, type CancelOrderIntentParams as af, type ChainFilter as ag, type CheckoutIntentItem as ah, type ClaimConditions as ai, type CollectionServiceId as aj, type CollectionSort as ak, type CollectionTokensSort as al, type ConfirmRemixOfferParams as am, type ConfirmSelfRemixParams as an, type ConsiderationItem as ao, type CreateCheckoutIntentParams as ap, type CreateCoinIntentParams as aq, type CreateCollectionIntentParams as ar, type CreateCounterOfferIntentParams as as, type CreateDropParams as at, type CreateListingIntentParams as au, type CreateMembershipParams as av, type CreateMintIntentParams as aw, type CreatePopCollectionParams as ax, type CreateRemixOfferParams as ay, type CreateSponsorshipOfferIntentParams as az, type AcceptSponsorshipProposalIntentParams as b, type OrderDetails as b0, type OrderParameters as b1, type OrderStatus as b2, type PlaceSponsorshipBidIntentParams as b3, type PopBatchEligibilityItem as b4, type PopClaimStatus as b5, type PopEventType as b6, type ProposeSponsorshipParams as b7, type RejectSponsorshipProposalIntentParams as b8, type RemixOfferStatus as b9, type ResolvedConfig as ba, type RetractSponsorshipBidIntentParams as bb, type RetryOptions as bc, type ServiceEventDeclaration as bd, type SetSponsorshipOfferOpenIntentParams as be, type SortOrder as bf, type TenantPlan as bg, type TierServiceId as bh, type TxResult as bi, type WebhookEventType as bj, type WebhookStatus as bk, type WithdrawSponsorshipProposalIntentParams as bl, resolveConfig as bm, resolveFeeConfig as bn, type ActivityType as c, type ApiActivitiesQuery as d, type ApiActivity as e, type ApiActivityPrice as f, type ApiAdminCollectionClaim as g, type ApiAppSource as h, type ApiBusinessProvisioning as i, type ApiChain as j, type ApiCheckoutIntentResult as k, ApiClient as l, type ApiCoin as m, type ApiCoinPrice as n, type ApiCoinPrices as o, type ApiCoinsQuery as p, type ApiCollection as q, type ApiCollectionClaim as r, type ApiCollectionProfile as s, type ApiCollectionSlugClaim as t, type ApiCollectionsQuery as u, type ApiComment as v, type ApiCounterOffersQuery as w, type ApiCreatorListResult as x, type ApiCreatorProfile as y, type ApiIntent as z };
1304
+ export { type ApiRewardsConfig as $, type AcceptSponsorshipBidIntentParams as A, type ApiIntent as B, type ApiIntentCreated as C, type ApiKeyStatus as D, type ApiMeta as E, type ApiMetadataSignedUrl as F, type ApiMetadataUpload as G, type ApiOrder as H, type ApiOrderConsideration as I, type ApiOrderOffer as J, type ApiOrderPrice as K, type ApiOrderTokenMeta as L, type ApiOrderTxHash as M, type ApiOrdersQuery as N, type ApiPointEvent as O, type ApiPortalKey as P, type ApiPortalKeyCreated as Q, type ResolvedFeeConfig as R, type ServiceDefinition as S, type ApiPortalMe as T, type ApiPublicRemix as U, type ApiRemixOffer as V, type ApiRemixOfferPrice as W, type ApiRemixOffersQuery as X, type ApiResponse as Y, type ApiRewardsBadge as Z, type ApiRewardsBatchEntry as _, type ServiceCapability as a, type OpenLicense as a$, type ApiRewardsLeaderboardEntry as a0, type ApiRewardsLevel as a1, type ApiSearchCollectionResult as a2, type ApiSearchCreatorResult as a3, type ApiSearchResult as a4, type ApiSearchTokenResult as a5, type ApiToken as a6, type ApiTokenBalance as a7, type ApiTokenMetadata as a8, type ApiUsageDay as a9, type CreateSponsorshipOfferIntentParams as aA, type CreateSponsorshipOfferParams as aB, type CreateSponsorshipProposalIntentParams as aC, type CreateTicketParams as aD, type CreateTierIntentParams as aE, type CreateWebhookParams as aF, type DropMintStatus as aG, type EnforcementDeclaration as aH, type FactoryFamilyServiceId as aI, type FeeConfig as aJ, FeeConfigSchema as aK, type FulfillOrderIntentParams as aL, type IPType as aM, type IntentCall as aN, type IntentStatus as aO, type IntentType as aP, type IpAttribute as aQ, type IpNftMetadata as aR, type LaunchCoinIntentParams as aS, type MakeOfferIntentParams as aT, MedialaneApiError as aU, type MedialaneConfig as aV, type MedialaneErrorCode as aW, type MintMembershipsParams as aX, type MintTicketsParams as aY, OPEN_LICENSES as aZ, type OfferItem as a_, type ApiUserRewards as aa, type ApiUserWallet as ab, type ApiWalletActivity as ac, type ApiWebhookCreated as ad, type ApiWebhookEndpoint as ae, type AutoRemixOfferParams as af, type CancelOrderIntentParams as ag, type ChainFilter as ah, type CheckoutIntentItem as ai, type ClaimConditions as aj, type CollectionServiceId as ak, type CollectionSort as al, type CollectionTokensSort as am, type ConfirmRemixOfferParams as an, type ConfirmSelfRemixParams as ao, type ConsiderationItem as ap, type CreateCheckoutIntentParams as aq, type CreateCoinIntentParams as ar, type CreateCollectionIntentParams as as, type CreateCounterOfferIntentParams as at, type CreateDropParams as au, type CreateListingIntentParams as av, type CreateMembershipParams as aw, type CreateMintIntentParams as ax, type CreatePopCollectionParams as ay, type CreateRemixOfferParams as az, type AcceptSponsorshipProposalIntentParams as b, type Order as b0, type OrderDetails as b1, type OrderParameters as b2, type OrderStatus as b3, type PlaceSponsorshipBidIntentParams as b4, type PopBatchEligibilityItem as b5, type PopClaimStatus as b6, type PopEventType as b7, type ProposeSponsorshipParams as b8, type RejectSponsorshipProposalIntentParams as b9, type RemixOfferStatus as ba, type ResolvedConfig as bb, type RetractSponsorshipBidIntentParams as bc, type RetryOptions as bd, type ServiceEventDeclaration as be, type SetSponsorshipOfferOpenIntentParams as bf, type SortOrder as bg, type TenantPlan as bh, type TierServiceId as bi, type TxResult as bj, type WebhookEventType as bk, type WebhookStatus as bl, type WithdrawSponsorshipProposalIntentParams as bm, resolveConfig as bn, resolveFeeConfig as bo, type ActivityType as c, type ApiActivitiesQuery as d, type ApiActivity as e, type ApiActivityPrice as f, type ApiAdminCollectionClaim as g, type ApiAppSource as h, type ApiBusinessProvisioning as i, type ApiChain as j, type ApiCheckoutIntentResult as k, ApiClient as l, type ApiCoin as m, type ApiCoinClaimResult as n, type ApiCoinPrice as o, type ApiCoinPrices as p, type ApiCoinsQuery as q, type ApiCollection as r, type ApiCollectionClaim as s, type ApiCollectionProfile as t, type ApiCollectionSlugClaim as u, type ApiCollectionsQuery as v, type ApiComment as w, type ApiCounterOffersQuery as x, type ApiCreatorListResult as y, type ApiCreatorProfile as z };
@@ -199,6 +199,7 @@ interface ApiMeta {
199
199
  page: number;
200
200
  limit: number;
201
201
  total?: number;
202
+ counts?: Record<string, number>;
202
203
  }
203
204
  interface ApiResponse<T> {
204
205
  data: T;
@@ -373,6 +374,13 @@ interface ApiCoinPrice {
373
374
  usdc: number;
374
375
  }
375
376
  type ApiCoinPrices = Record<string, ApiCoinPrice | null>;
377
+ type ApiCoinClaimResult = {
378
+ verified: true;
379
+ coin: ApiCoin | null;
380
+ } | {
381
+ verified: false;
382
+ reason: "owner_mismatch" | "owner_check_failed" | "not_erc20" | "no_total_supply";
383
+ };
376
384
  interface ApiCoinsQuery {
377
385
  chain?: ChainFilter;
378
386
  page?: number;
@@ -1163,6 +1171,8 @@ declare class ApiClient {
1163
1171
  data: ApiCoin;
1164
1172
  }>;
1165
1173
  getCoinPrices(): Promise<ApiResponse<ApiCoinPrices>>;
1174
+ claimCoin(coinAddress: string, siwsToken: string): Promise<ApiCoinClaimResult>;
1175
+ getCoinClaims(status?: string): Promise<ApiResponse<ApiCollectionClaim[]>>;
1166
1176
  updateCoinProfile(contract: string, data: {
1167
1177
  image?: string;
1168
1178
  description?: string;
@@ -1291,4 +1301,4 @@ interface ProposeSponsorshipParams {
1291
1301
  royaltyBps: bigint | string;
1292
1302
  }
1293
1303
 
1294
- export { type ApiRewardsLeaderboardEntry as $, type AcceptSponsorshipBidIntentParams as A, type ApiIntentCreated as B, type ApiKeyStatus as C, type ApiMeta as D, type ApiMetadataSignedUrl as E, type ApiMetadataUpload as F, type ApiOrder as G, type ApiOrderConsideration as H, type ApiOrderOffer as I, type ApiOrderPrice as J, type ApiOrderTokenMeta as K, type ApiOrderTxHash as L, type ApiOrdersQuery as M, type ApiPointEvent as N, type ApiPortalKey as O, type ApiPortalKeyCreated as P, type ApiPortalMe as Q, type ResolvedFeeConfig as R, type ServiceDefinition as S, type ApiPublicRemix as T, type ApiRemixOffer as U, type ApiRemixOfferPrice as V, type ApiRemixOffersQuery as W, type ApiResponse as X, type ApiRewardsBadge as Y, type ApiRewardsBatchEntry as Z, type ApiRewardsConfig as _, type ServiceCapability as a, type Order as a$, type ApiRewardsLevel as a0, type ApiSearchCollectionResult as a1, type ApiSearchCreatorResult as a2, type ApiSearchResult as a3, type ApiSearchTokenResult as a4, type ApiToken as a5, type ApiTokenBalance as a6, type ApiTokenMetadata as a7, type ApiUsageDay as a8, type ApiUserRewards as a9, type CreateSponsorshipOfferParams as aA, type CreateSponsorshipProposalIntentParams as aB, type CreateTicketParams as aC, type CreateTierIntentParams as aD, type CreateWebhookParams as aE, type DropMintStatus as aF, type EnforcementDeclaration as aG, type FactoryFamilyServiceId as aH, type FeeConfig as aI, FeeConfigSchema as aJ, type FulfillOrderIntentParams as aK, type IPType as aL, type IntentCall as aM, type IntentStatus as aN, type IntentType as aO, type IpAttribute as aP, type IpNftMetadata as aQ, type LaunchCoinIntentParams as aR, type MakeOfferIntentParams as aS, MedialaneApiError as aT, type MedialaneConfig as aU, type MedialaneErrorCode as aV, type MintMembershipsParams as aW, type MintTicketsParams as aX, OPEN_LICENSES as aY, type OfferItem as aZ, type OpenLicense as a_, type ApiUserWallet as aa, type ApiWalletActivity as ab, type ApiWebhookCreated as ac, type ApiWebhookEndpoint as ad, type AutoRemixOfferParams as ae, type CancelOrderIntentParams as af, type ChainFilter as ag, type CheckoutIntentItem as ah, type ClaimConditions as ai, type CollectionServiceId as aj, type CollectionSort as ak, type CollectionTokensSort as al, type ConfirmRemixOfferParams as am, type ConfirmSelfRemixParams as an, type ConsiderationItem as ao, type CreateCheckoutIntentParams as ap, type CreateCoinIntentParams as aq, type CreateCollectionIntentParams as ar, type CreateCounterOfferIntentParams as as, type CreateDropParams as at, type CreateListingIntentParams as au, type CreateMembershipParams as av, type CreateMintIntentParams as aw, type CreatePopCollectionParams as ax, type CreateRemixOfferParams as ay, type CreateSponsorshipOfferIntentParams as az, type AcceptSponsorshipProposalIntentParams as b, type OrderDetails as b0, type OrderParameters as b1, type OrderStatus as b2, type PlaceSponsorshipBidIntentParams as b3, type PopBatchEligibilityItem as b4, type PopClaimStatus as b5, type PopEventType as b6, type ProposeSponsorshipParams as b7, type RejectSponsorshipProposalIntentParams as b8, type RemixOfferStatus as b9, type ResolvedConfig as ba, type RetractSponsorshipBidIntentParams as bb, type RetryOptions as bc, type ServiceEventDeclaration as bd, type SetSponsorshipOfferOpenIntentParams as be, type SortOrder as bf, type TenantPlan as bg, type TierServiceId as bh, type TxResult as bi, type WebhookEventType as bj, type WebhookStatus as bk, type WithdrawSponsorshipProposalIntentParams as bl, resolveConfig as bm, resolveFeeConfig as bn, type ActivityType as c, type ApiActivitiesQuery as d, type ApiActivity as e, type ApiActivityPrice as f, type ApiAdminCollectionClaim as g, type ApiAppSource as h, type ApiBusinessProvisioning as i, type ApiChain as j, type ApiCheckoutIntentResult as k, ApiClient as l, type ApiCoin as m, type ApiCoinPrice as n, type ApiCoinPrices as o, type ApiCoinsQuery as p, type ApiCollection as q, type ApiCollectionClaim as r, type ApiCollectionProfile as s, type ApiCollectionSlugClaim as t, type ApiCollectionsQuery as u, type ApiComment as v, type ApiCounterOffersQuery as w, type ApiCreatorListResult as x, type ApiCreatorProfile as y, type ApiIntent as z };
1304
+ export { type ApiRewardsConfig as $, type AcceptSponsorshipBidIntentParams as A, type ApiIntent as B, type ApiIntentCreated as C, type ApiKeyStatus as D, type ApiMeta as E, type ApiMetadataSignedUrl as F, type ApiMetadataUpload as G, type ApiOrder as H, type ApiOrderConsideration as I, type ApiOrderOffer as J, type ApiOrderPrice as K, type ApiOrderTokenMeta as L, type ApiOrderTxHash as M, type ApiOrdersQuery as N, type ApiPointEvent as O, type ApiPortalKey as P, type ApiPortalKeyCreated as Q, type ResolvedFeeConfig as R, type ServiceDefinition as S, type ApiPortalMe as T, type ApiPublicRemix as U, type ApiRemixOffer as V, type ApiRemixOfferPrice as W, type ApiRemixOffersQuery as X, type ApiResponse as Y, type ApiRewardsBadge as Z, type ApiRewardsBatchEntry as _, type ServiceCapability as a, type OpenLicense as a$, type ApiRewardsLeaderboardEntry as a0, type ApiRewardsLevel as a1, type ApiSearchCollectionResult as a2, type ApiSearchCreatorResult as a3, type ApiSearchResult as a4, type ApiSearchTokenResult as a5, type ApiToken as a6, type ApiTokenBalance as a7, type ApiTokenMetadata as a8, type ApiUsageDay as a9, type CreateSponsorshipOfferIntentParams as aA, type CreateSponsorshipOfferParams as aB, type CreateSponsorshipProposalIntentParams as aC, type CreateTicketParams as aD, type CreateTierIntentParams as aE, type CreateWebhookParams as aF, type DropMintStatus as aG, type EnforcementDeclaration as aH, type FactoryFamilyServiceId as aI, type FeeConfig as aJ, FeeConfigSchema as aK, type FulfillOrderIntentParams as aL, type IPType as aM, type IntentCall as aN, type IntentStatus as aO, type IntentType as aP, type IpAttribute as aQ, type IpNftMetadata as aR, type LaunchCoinIntentParams as aS, type MakeOfferIntentParams as aT, MedialaneApiError as aU, type MedialaneConfig as aV, type MedialaneErrorCode as aW, type MintMembershipsParams as aX, type MintTicketsParams as aY, OPEN_LICENSES as aZ, type OfferItem as a_, type ApiUserRewards as aa, type ApiUserWallet as ab, type ApiWalletActivity as ac, type ApiWebhookCreated as ad, type ApiWebhookEndpoint as ae, type AutoRemixOfferParams as af, type CancelOrderIntentParams as ag, type ChainFilter as ah, type CheckoutIntentItem as ai, type ClaimConditions as aj, type CollectionServiceId as ak, type CollectionSort as al, type CollectionTokensSort as am, type ConfirmRemixOfferParams as an, type ConfirmSelfRemixParams as ao, type ConsiderationItem as ap, type CreateCheckoutIntentParams as aq, type CreateCoinIntentParams as ar, type CreateCollectionIntentParams as as, type CreateCounterOfferIntentParams as at, type CreateDropParams as au, type CreateListingIntentParams as av, type CreateMembershipParams as aw, type CreateMintIntentParams as ax, type CreatePopCollectionParams as ay, type CreateRemixOfferParams as az, type AcceptSponsorshipProposalIntentParams as b, type Order as b0, type OrderDetails as b1, type OrderParameters as b2, type OrderStatus as b3, type PlaceSponsorshipBidIntentParams as b4, type PopBatchEligibilityItem as b5, type PopClaimStatus as b6, type PopEventType as b7, type ProposeSponsorshipParams as b8, type RejectSponsorshipProposalIntentParams as b9, type RemixOfferStatus as ba, type ResolvedConfig as bb, type RetractSponsorshipBidIntentParams as bc, type RetryOptions as bd, type ServiceEventDeclaration as be, type SetSponsorshipOfferOpenIntentParams as bf, type SortOrder as bg, type TenantPlan as bh, type TierServiceId as bi, type TxResult as bj, type WebhookEventType as bk, type WebhookStatus as bl, type WithdrawSponsorshipProposalIntentParams as bm, resolveConfig as bn, resolveFeeConfig as bo, type ActivityType as c, type ApiActivitiesQuery as d, type ApiActivity as e, type ApiActivityPrice as f, type ApiAdminCollectionClaim as g, type ApiAppSource as h, type ApiBusinessProvisioning as i, type ApiChain as j, type ApiCheckoutIntentResult as k, ApiClient as l, type ApiCoin as m, type ApiCoinClaimResult as n, type ApiCoinPrice as o, type ApiCoinPrices as p, type ApiCoinsQuery as q, type ApiCollection as r, type ApiCollectionClaim as s, type ApiCollectionProfile as t, type ApiCollectionSlugClaim as u, type ApiCollectionsQuery as v, type ApiComment as w, type ApiCounterOffersQuery as x, type ApiCreatorListResult as y, type ApiCreatorProfile as z };
@@ -763,6 +763,18 @@ var ApiClient = class {
763
763
  getCoinPrices() {
764
764
  return this.get("/v1/coins/prices");
765
765
  }
766
+ claimCoin(coinAddress, siwsToken) {
767
+ return this.request("/v1/coins/claim", {
768
+ method: "POST",
769
+ headers: { Authorization: `Bearer ${siwsToken}` },
770
+ body: JSON.stringify({ coinAddress })
771
+ });
772
+ }
773
+ getCoinClaims(status = "PENDING") {
774
+ return this.get(
775
+ `/v1/coins/claims?status=${encodeURIComponent(status)}`
776
+ );
777
+ }
766
778
  updateCoinProfile(contract, data, siwsToken) {
767
779
  return this.request(`/v1/coins/${this.addr(contract)}`, {
768
780
  method: "PATCH",