@itm-studio/partner-sdk 0.6.4 → 0.6.6

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@itm-studio/partner-sdk",
3
- "version": "0.6.4",
3
+ "version": "0.6.6",
4
4
  "description": "TypeScript SDK for the ITM Partner API — typed GraphQL client with zero introspection required",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -706,6 +706,8 @@ type Moment {
706
706
  description: String
707
707
  blurb: String!
708
708
  slug: String!
709
+ """Canonical public URL on ITM. Always returned, whatever the moment's visibility; check isPrivate and status before sharing it."""
710
+ publicUrl: String!
709
711
  startDate: DateTime!
710
712
  endDate: DateTime!
711
713
  isPrivate: Boolean!
@@ -915,6 +917,8 @@ type MerchSize {
915
917
  type Merch {
916
918
  uid: ID!
917
919
  name: String!
920
+ """Canonical public URL on ITM. Always returned, whatever the item's visibility; check isLive before sharing it."""
921
+ publicUrl: String!
918
922
  description: String
919
923
  """Price in ITM cents (major units times 100)."""
920
924
  price: Float!
@@ -1195,6 +1199,8 @@ type Echo {
1195
1199
  type: EchoType!
1196
1200
  name: String!
1197
1201
  slug: String
1202
+ """Canonical public URL on ITM. Always returned, whatever the echo's visibility; check isPublic and publishTime before sharing it."""
1203
+ publicUrl: String!
1198
1204
  description: String
1199
1205
  """Rich text body for POST-type echoes."""
1200
1206
  postBody: String
@@ -1219,6 +1225,8 @@ type BrandDrop {
1219
1225
  uid: ID!
1220
1226
  name: String!
1221
1227
  slug: String!
1228
+ """Canonical public URL on ITM. Always returned, whatever the drop's visibility; check isPublic and isActive before sharing it."""
1229
+ publicUrl: String!
1222
1230
  subtitle: String
1223
1231
  disclosures: String
1224
1232
  isPublic: Boolean!
@@ -1761,6 +1769,7 @@ type GetPartnerMembershipTiersResponse {
1761
1769
  }
1762
1770
 
1763
1771
  type PartnerMember {
1772
+ signupFormResponseUid: String
1764
1773
  billingInterval: MembershipBillingInterval
1765
1774
  cancelAtPeriodEnd: Boolean!
1766
1775
  cancelledAt: DateTime
@@ -1799,6 +1808,7 @@ type PartnerMemberTier {
1799
1808
  }
1800
1809
 
1801
1810
  type PartnerMembershipTier {
1811
+ signupFormUid: String
1802
1812
  """Memberships currently ACTIVE or PAST_DUE on this tier"""
1803
1813
  activeMemberCount: Int!
1804
1814
  benefits: [String!]!
@@ -1830,6 +1840,8 @@ type PartnerMembershipTier {
1830
1840
  Amount in hundredths of the currency's major unit (always x100, including zero-decimal currencies such as JPY)
1831
1841
  """
1832
1842
  price: Int!
1843
+ """Canonical public URL on ITM. Always returned, whatever the pass's visibility; check isPublic and isActive before sharing it."""
1844
+ publicUrl: String!
1833
1845
  slug: String!
1834
1846
  sortOrder: Int!
1835
1847
  supplyCap: Int
@@ -1992,6 +2004,10 @@ type PartnerAppLogin {
1992
2004
  }
1993
2005
 
1994
2006
  type Query {
2007
+ getPartnerForms(input: GetPartnerFormsInput): GetFormsPaginatedResponse!
2008
+ getPartnerForm(uid: String!): Form!
2009
+ getPartnerFormResponses(input: GetPartnerFormResponsesInput): GetPartnerFormResponsesResponse!
2010
+
1995
2011
  """
1996
2012
  Itemized POS orders for an owned moment, newest first. Defaults to 50 orders and caps take at 100.
1997
2013
  """
@@ -3646,3 +3662,189 @@ type MomentGuestListTotals {
3646
3662
  peopleRemaining: Int!
3647
3663
  plusOnes: Int!
3648
3664
  }
3665
+
3666
+ # Partner forms and response reads
3667
+ type Form {
3668
+ allowMultipleResponses: Boolean!
3669
+ buttonText: String!
3670
+ category: String
3671
+ createdAt: DateTime!
3672
+ deletedAt: DateTime
3673
+ description: String
3674
+ faqs: [FormFaq!]!
3675
+ fields: [FormField!]!
3676
+ isActive: Boolean!
3677
+ isPublic: Boolean!
3678
+ label: String
3679
+ labelColor: String
3680
+ mode: FormResponseMode!
3681
+ name: String!
3682
+ preSubmitCalloutText: String
3683
+ """Canonical public URL on ITM. Always returned, whatever the form's visibility; check isPublic and isActive before sharing it."""
3684
+ publicUrl: String!
3685
+ relevancyScoringContext: String
3686
+ relevancyScoringEnabled: Boolean!
3687
+ responsesCount: Int!
3688
+ sections: [FormFieldSection!]!
3689
+ slug: String!
3690
+ source: FormSource!
3691
+ successMessageBody: String!
3692
+ successMessageTitle: String!
3693
+ uid: ID!
3694
+ updatedAt: DateTime!
3695
+ }
3696
+
3697
+ type FormFaq {
3698
+ answer: String!
3699
+ createdAt: DateTime!
3700
+ isActive: Boolean!
3701
+ question: String!
3702
+ sortOrder: Int!
3703
+ uid: ID!
3704
+ updatedAt: DateTime!
3705
+ }
3706
+
3707
+ type FormField {
3708
+ createdAt: DateTime!
3709
+ defaultValue: String
3710
+ deletedAt: DateTime
3711
+ isRequired: Boolean!
3712
+ label: String!
3713
+ """
3714
+ Pictures on the choices of a single- or multi-choice question. Empty when there are none.
3715
+ """
3716
+ optionImages: [FormFieldOptionImage!]!
3717
+ options: [String!]
3718
+ placeholder: String
3719
+ sectionUid: String
3720
+ sortOrder: Int!
3721
+ subLabel: String
3722
+ type: FormFieldType!
3723
+ uid: ID!
3724
+ updatedAt: DateTime!
3725
+ validationSchema: String
3726
+ }
3727
+
3728
+ """A picture shown with one choice of a single- or multi-choice question."""
3729
+ type FormFieldOptionImage {
3730
+ image: MediaAsset!
3731
+ """The choice this picture belongs to, as listed in `options`."""
3732
+ option: String!
3733
+ }
3734
+
3735
+ type FormFieldSection {
3736
+ createdAt: DateTime!
3737
+ deletedAt: DateTime
3738
+ description: String
3739
+ sortOrder: Int!
3740
+ title: String!
3741
+ uid: ID!
3742
+ updatedAt: DateTime!
3743
+ }
3744
+
3745
+ enum FormFieldType {
3746
+ ADDRESS
3747
+ BOOLEAN
3748
+ DATE
3749
+ EMAIL
3750
+ ETHEREUM_WALLET
3751
+ FULL_NAME
3752
+ MULTI_SELECT
3753
+ NUMBER
3754
+ PHONE
3755
+ SELECT
3756
+ SIGNATURE
3757
+ STRING
3758
+ UPLOAD
3759
+ URL
3760
+ }
3761
+
3762
+ enum FormResponseMode {
3763
+ CHAT
3764
+ FORM
3765
+ SINGLE_PAGE
3766
+ }
3767
+
3768
+ enum FormSource {
3769
+ AGENT
3770
+ AUTO
3771
+ MANUAL
3772
+ }
3773
+
3774
+ type GetFormsPaginatedResponse {
3775
+ forms: [Form!]!
3776
+ hasNextPage: Boolean!
3777
+ nextCursor: String
3778
+ totalCount: Int!
3779
+ }
3780
+
3781
+ input GetPartnerFormsInput {
3782
+ cursor: String
3783
+ """Include archived forms. Default false."""
3784
+ includeArchived: Boolean
3785
+ isActive: Boolean
3786
+ """Case-insensitive form name search, at most 100 characters."""
3787
+ search: String
3788
+ sources: [FormSource!]
3789
+ """Page size. Default 50, maximum 100."""
3790
+ take: Int
3791
+ }
3792
+
3793
+ input GetPartnerFormResponsesInput {
3794
+ createdAtBefore: DateTime
3795
+ createdAtFrom: DateTime
3796
+ cursor: String
3797
+ """
3798
+ At most 100 customer UIDs, matching getPartnerMembers.customer.uid and getPartnerAudience.uid.
3799
+ """
3800
+ customerUids: [String!]
3801
+ """At most 100 form UIDs, all owned by the authenticated brand."""
3802
+ formUids: [String!]
3803
+ """
3804
+ At most 100 response UIDs, for example getPartnerMembers.signupFormResponseUid.
3805
+ """
3806
+ responseUids: [String!]
3807
+ """Page size. Default 50, maximum 100."""
3808
+ take: Int
3809
+ }
3810
+
3811
+ type PartnerFormFieldResponse {
3812
+ createdAt: DateTime!
3813
+ """
3814
+ Current question definition, including archived questions that still have answers.
3815
+ """
3816
+ formField: FormField!
3817
+ isValid: Boolean!
3818
+ uid: ID!
3819
+ updatedAt: DateTime!
3820
+ validationError: String
3821
+ value: JSON
3822
+ valueArray: JSON
3823
+ valueBoolean: Boolean
3824
+ valueDate: DateTime
3825
+ valueNumber: Float
3826
+ valueString: String
3827
+ }
3828
+
3829
+ type PartnerFormResponse {
3830
+ contextType: String
3831
+ createdAt: DateTime!
3832
+ customer: PartnerMemberCustomer!
3833
+ extraData: String
3834
+ form: Form!
3835
+ formFieldResponses: [PartnerFormFieldResponse!]!
3836
+ relevancyScore: Int
3837
+ relevancyScoreDetails: JSON
3838
+ relevancyScoredAt: DateTime
3839
+ responseData: JSON!
3840
+ uid: ID!
3841
+ updatedAt: DateTime!
3842
+ }
3843
+
3844
+ type GetPartnerFormResponsesResponse {
3845
+ formResponses: [PartnerFormResponse!]!
3846
+ hasNextPage: Boolean!
3847
+ nextCursor: String
3848
+ totalCount: Int!
3849
+ }
3850
+ # End partner forms and response reads