app.graphql 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773
  1. # The application that created the order.
  2. type OrderApp {
  3. # The application icon.
  4. icon: Image!
  5. # The application ID.
  6. id: ID!
  7. # The name of the application.
  8. name: String!
  9. }
  10. # Requirements that must be met before an app can be installed.
  11. type FailedRequirement {
  12. # Action to be taken to resolve a failed requirement, including URL link.
  13. action: NavigationItem
  14. # A concise set of copy strings to be displayed to merchants, to guide them in resolving problems your app
  15. # encounters when trying to make use of their Shop and its resources.
  16. message: String!
  17. }
  18. # A navigation item, holding basic link attributes.
  19. type NavigationItem {
  20. # The unique identifier of the navigation item.
  21. id: String!
  22. # The name of the navigation item.
  23. title: String!
  24. # The URL of the page that the navigation item links to.
  25. url: URL!
  26. }
  27. # Reports the status of shops and their resources and displays this information
  28. # within Shopify admin. AppFeedback is used to notify merchants about steps they need to take
  29. # to set up an app on their store.
  30. type AppFeedback {
  31. # The application associated to the feedback.
  32. app: App!
  33. # A link to where merchants can resolve errors.
  34. link: Link
  35. # The feedback message presented to the merchant.
  36. messages: [UserError!]!
  37. }
  38. # Represents an installed application on a shop.
  39. type AppInstallation implements HasMetafields&Node {
  40. # The access scopes granted to the application by a merchant during installation.
  41. accessScopes: [AccessScope!]!
  42. # The active application subscriptions billed to the shop on a recurring basis.
  43. activeSubscriptions: [AppSubscription!]!
  44. # All subscriptions created for a shop.
  45. allSubscriptions(
  46. first: Int
  47. after: String
  48. last: Int
  49. before: String
  50. reverse: Boolean = false
  51. sortKey: AppSubscriptionSortKeys = CREATED_AT
  52. ): AppSubscriptionConnection!
  53. # Application which is installed.
  54. app: App!
  55. # Credits that can be used towards future app purchases.
  56. credits(
  57. first: Int
  58. after: String
  59. last: Int
  60. before: String
  61. reverse: Boolean = false
  62. sortKey: AppTransactionSortKeys = CREATED_AT
  63. ): AppCreditConnection!
  64. # A globally-unique identifier.
  65. id: ID!
  66. # The URL to launch the application.
  67. launchUrl: URL!
  68. # Returns a metafield by namespace and key that belongs to the resource.
  69. metafield(namespace: String!key: String!): Metafield
  70. # List of metafields that belong to the resource.
  71. metafields(
  72. namespace: String
  73. first: Int
  74. after: String
  75. last: Int
  76. before: String
  77. reverse: Boolean = false
  78. ): MetafieldConnection!
  79. # One-time purchases to a shop.
  80. oneTimePurchases(
  81. first: Int
  82. after: String
  83. last: Int
  84. before: String
  85. reverse: Boolean = false
  86. sortKey: AppTransactionSortKeys = CREATED_AT
  87. ): AppPurchaseOneTimeConnection!
  88. # Returns a private metafield by namespace and key that belongs to the resource.
  89. privateMetafield(namespace: String!key: String!): PrivateMetafield
  90. # List of private metafields that belong to the resource.
  91. privateMetafields(
  92. namespace: String
  93. first: Int
  94. after: String
  95. last: Int
  96. before: String
  97. reverse: Boolean = false
  98. ): PrivateMetafieldConnection!
  99. # The publication associated with the installed application.
  100. publication: Publication
  101. # The records that track the externally-captured revenue for the app. The records are used for revenue attribution purposes.
  102. revenueAttributionRecords(
  103. first: Int
  104. after: String
  105. last: Int
  106. before: String
  107. reverse: Boolean = false
  108. sortKey: AppRevenueAttributionRecordSortKeys = CREATED_AT
  109. ): AppRevenueAttributionRecordConnection!
  110. # The URL to uninstall the application.
  111. uninstallUrl: URL
  112. }
  113. # Provides users access to services and/or features for a duration of time.
  114. type AppSubscription implements Node {
  115. # The date and time when the app subscription was created.
  116. createdAt: DateTime!
  117. # The date and time when the current app subscription period ends. Returns null if the subscription isn't active.
  118. currentPeriodEnd: DateTime
  119. # A globally-unique identifier.
  120. id: ID!
  121. # The plans attached to the app subscription.
  122. lineItems: [AppSubscriptionLineItem!]!
  123. # The name of the app subscription.
  124. name: String!
  125. # The URL that the merchant is redirected to after approving the app subscription.
  126. returnUrl: URL!
  127. # The status of the app subscription.
  128. status: AppSubscriptionStatus!
  129. # Specifies whether the app subscription is a test transaction.
  130. test: Boolean!
  131. # The number of free trial days, starting at the subscription's creation date, by which billing is delayed.
  132. trialDays: Int!
  133. }
  134. # The plan attached to an app subscription.
  135. type AppSubscriptionLineItem {
  136. # A globally-unique identifier.
  137. id: ID!
  138. # The pricing model for the app subscription.
  139. plan: AppPlanV2!
  140. # A list of the store's usage records for a usage pricing plan.
  141. usageRecords(
  142. first: Int
  143. after: String
  144. last: Int
  145. before: String
  146. reverse: Boolean = false
  147. sortKey: AppUsageRecordSortKeys = CREATED_AT
  148. ): AppUsageRecordConnection!
  149. }
  150. # The app plan that the merchant is subscribed to.
  151. type AppPlanV2 {
  152. # The plan billed to a shop on a recurring basis.
  153. pricingDetails: AppPricingDetails!
  154. }
  155. # A link to direct users to.
  156. type Link implements HasPublishedTranslations {
  157. # A context-sensitive label for the link.
  158. label: String!
  159. # The translations associated with the resource.
  160. translations(locale: String!marketId: ID): [PublishedTranslation!]!
  161. # The URL that the link visits.
  162. url: URL!
  163. }
  164. # A publication is a group of products and collections that is published to an app.
  165. type Publication implements Node {
  166. # The app associated with the publication.
  167. app: App!
  168. # The collection publications for the list of collections published to the publication.
  169. collectionPublicationsV3(
  170. first: Int
  171. after: String
  172. last: Int
  173. before: String
  174. reverse: Boolean = false
  175. ): ResourcePublicationConnection!
  176. # The list of collections published to the publication.
  177. collections(
  178. first: Int
  179. after: String
  180. last: Int
  181. before: String
  182. reverse: Boolean = false
  183. ): CollectionConnection!
  184. # Whether the collection is available to the publication.
  185. hasCollection(id: ID!): Boolean!
  186. # A globally-unique identifier.
  187. id: ID!
  188. # Name of the publication.
  189. name: String!
  190. # The product publications for the list of products published to the publication.
  191. productPublicationsV3(
  192. first: Int
  193. after: String
  194. last: Int
  195. before: String
  196. reverse: Boolean = false
  197. ): ResourcePublicationConnection!
  198. # The list of products published to the publication.
  199. products(
  200. first: Int
  201. after: String
  202. last: Int
  203. before: String
  204. reverse: Boolean = false
  205. ): ProductConnection!
  206. # Whether the publication supports future publishing.
  207. supportsFuturePublishing: Boolean!
  208. }
  209. # App credits can be applied by the merchant towards future app purchases, subscriptions, or usage records in Shopify.
  210. type AppCredit implements Node {
  211. # The amount that can be used towards future app purchases in Shopify.
  212. amount: MoneyV2!
  213. # The date and time when the app credit was created.
  214. createdAt: DateTime!
  215. # The description of the app credit.
  216. description: String!
  217. # A globally-unique identifier.
  218. id: ID!
  219. # Whether the app credit is a test transaction.
  220. test: Boolean!
  221. }
  222. # Services and features purchased once by a store.
  223. type AppPurchaseOneTime implements AppPurchase&Node {
  224. # The date and time when the app purchase occurred.
  225. createdAt: DateTime!
  226. # A globally-unique identifier.
  227. id: ID!
  228. # The name of the app purchase.
  229. name: String!
  230. # The amount to be charged to the store for the app purchase.
  231. price: MoneyV2!
  232. # The status of the app purchase.
  233. status: AppPurchaseStatus!
  234. # Whether the app purchase is a test transaction.
  235. test: Boolean!
  236. }
  237. # Represents app revenue that was captured externally by the partner.
  238. type AppRevenueAttributionRecord implements Node {
  239. # The financial amount captured in this attribution.
  240. amount: MoneyV2!
  241. # The timestamp when the financial amount was captured.
  242. capturedAt: DateTime!
  243. # The timestamp at which this revenue attribution was issued.
  244. createdAt: DateTime!
  245. # A globally-unique identifier.
  246. id: ID!
  247. # The unique value submitted during the creation of the app revenue attribution record.
  248. # For more information, refer to Idempotent requests.
  249. idempotencyKey: String!
  250. # Indicates whether this is a test submission.
  251. test: Boolean!
  252. # The type of revenue attribution.
  253. type: AppRevenueAttributionType!
  254. }
  255. # Store usage for app subscriptions with usage pricing.
  256. type AppUsageRecord implements Node {
  257. # The date and time when the usage record was created.
  258. createdAt: DateTime!
  259. # The description of the app usage record.
  260. description: String!
  261. # A globally-unique identifier.
  262. id: ID!
  263. # The price of the usage record. The only permitted currency code is USD.
  264. price: MoneyV2!
  265. # Defines the usage pricing plan the merchant is subscribed to.
  266. subscriptionLineItem: AppSubscriptionLineItem!
  267. }
  268. # SEO information.
  269. type SEO {
  270. # SEO Description.
  271. description: String
  272. # SEO Title.
  273. title: String
  274. }
  275. # SEO information.
  276. input SEOInput {
  277. # SEO title of the product.
  278. title: String
  279. # SEO description of the product.
  280. description: String
  281. }
  282. # Represents feedback from apps about a resource, and the steps required to set up the apps on the shop.
  283. type ResourceFeedback {
  284. # List of AppFeedback detailing issues regarding a resource.
  285. details: [AppFeedback!]!
  286. # Summary of resource feedback pertaining to the resource.
  287. summary: String!
  288. }
  289. # Represents a Subscription Contract.
  290. type SubscriptionContract implements Node&SubscriptionContractBase {
  291. # The subscription app that the subscription contract is registered to.
  292. app: App
  293. # The URL of the subscription contract page on the subscription app.
  294. appAdminUrl: URL
  295. # The list of billing attempts associated with the subscription contract.
  296. billingAttempts(
  297. first: Int
  298. after: String
  299. last: Int
  300. before: String
  301. reverse: Boolean = false
  302. ): SubscriptionBillingAttemptConnection!
  303. # The billing policy associated with the subscription contract.
  304. billingPolicy: SubscriptionBillingPolicy!
  305. # The date and time when the subscription contract was created.
  306. createdAt: DateTime!
  307. # The currency that's used for the subscription contract.
  308. currencyCode: CurrencyCode!
  309. # A list of the custom attributes to be added to the generated orders.
  310. customAttributes: [Attribute!]!
  311. # The customer to whom the subscription contract belongs.
  312. customer: Customer
  313. # The customer payment method that's used for the subscription contract.
  314. customerPaymentMethod(showRevoked: Boolean = false): CustomerPaymentMethod
  315. # The delivery method for each billing of the subscription contract.
  316. deliveryMethod: SubscriptionDeliveryMethod
  317. # The delivery policy associated with the subscription contract.
  318. deliveryPolicy: SubscriptionDeliveryPolicy!
  319. # The delivery price for each billing of the subscription contract.
  320. deliveryPrice: MoneyV2!
  321. # The list of subscription discounts associated with the subscription contract.
  322. discounts(
  323. first: Int
  324. after: String
  325. last: Int
  326. before: String
  327. reverse: Boolean = false
  328. ): SubscriptionManualDiscountConnection!
  329. # A globally-unique identifier.
  330. id: ID!
  331. # The current status of the last payment.
  332. lastPaymentStatus: SubscriptionContractLastPaymentStatus
  333. # The number of lines associated with the subscription contract.
  334. lineCount: Int!
  335. # The list of subscription lines associated with the subscription contract.
  336. lines(
  337. first: Int
  338. after: String
  339. last: Int
  340. before: String
  341. reverse: Boolean = false
  342. ): SubscriptionLineConnection!
  343. # The next billing date for the subscription contract.
  344. nextBillingDate: DateTime
  345. # The note field that will be applied to the generated orders.
  346. note: String
  347. # A list of the subscription contract's orders.
  348. orders(
  349. first: Int
  350. after: String
  351. last: Int
  352. before: String
  353. reverse: Boolean = false
  354. ): OrderConnection!
  355. # The order from which this contract originated.
  356. originOrder: Order
  357. # The current status of the subscription contract.
  358. status: SubscriptionContractSubscriptionStatus!
  359. # The date and time when the subscription contract was updated.
  360. updatedAt: DateTime!
  361. }
  362. # A setting for a presentment currency.
  363. type CurrencySetting {
  364. # The currency's ISO code.
  365. currencyCode: CurrencyCode!
  366. # The full name of the currency.
  367. currencyName: String!
  368. # Whether the currency is enabled or not.
  369. # An enabled currency setting is visible to buyers and allows orders to be generated with that currency as presentment.
  370. enabled: Boolean!
  371. # The date and time when the active exchange rate for the currency was last modified.
  372. # It can be the automatic rate's creation date, or the manual rate's last updated at date if active.
  373. rateUpdatedAt: DateTime
  374. }
  375. # A unique string that represents the address of a Shopify store on the Internet.
  376. type Domain implements Node {
  377. # The host name of the domain. For example, example.com.
  378. host: String!
  379. # A globally-unique identifier.
  380. id: ID!
  381. # The localization of the domain, if the domain doesn't redirect.
  382. localization: DomainLocalization
  383. # The web presence of the domain.
  384. marketWebPresence: MarketWebPresence
  385. # Whether SSL is enabled.
  386. sslEnabled: Boolean!
  387. # The URL of the domain (for example, https://example.com).
  388. url: URL!
  389. }
  390. # The country and language settings assigned to a domain.
  391. type DomainLocalization {
  392. # The ISO codes for the domain’s alternate locales. For example, ["en"].
  393. alternateLocales: [String!]!
  394. # The ISO code for the country assigned to the domain. For example, "CA" or "*" for a domain set to "Rest of world".
  395. country: String
  396. # The ISO code for the domain’s default locale. For example, "en".
  397. defaultLocale: String!
  398. }
  399. # A custom page on the Online Store.
  400. type OnlineStorePage implements HasPublishedTranslations&Navigable&Node {
  401. # A default cursor that returns the single next record, sorted ascending by ID.
  402. defaultCursor: String!
  403. # A globally-unique identifier.
  404. id: ID!
  405. # The translations associated with the resource.
  406. translations(locale: String!marketId: ID): [PublishedTranslation!]!
  407. }
  408. # Automatic discount applications capture the intentions of a discount that was automatically applied.
  409. type AutomaticDiscountApplication implements DiscountApplication {
  410. # The method by which the discount's value is applied to its entitled items.
  411. allocationMethod: DiscountApplicationAllocationMethod!
  412. # An ordered index that can be used to identify the discount application and indicate the precedence
  413. # of the discount application for calculations.
  414. index: Int!
  415. # How the discount amount is distributed on the discounted lines.
  416. targetSelection: DiscountApplicationTargetSelection!
  417. # Whether the discount is applied on line items or shipping lines.
  418. targetType: DiscountApplicationTargetType!
  419. # The title of the discount application.
  420. title: String!
  421. # The value of the discount application.
  422. value: PricingValue!
  423. }
  424. # Discount code applications capture the intentions of a discount code at
  425. # he time that it is applied onto an order.
  426. #
  427. # Discount applications don't represent the actual final amount discounted on a line (line item or shipping line). The actual amount discounted on a line is represented by the DiscountAllocation object.
  428. type DiscountCodeApplication implements DiscountApplication {
  429. # The method by which the discount's value is applied to its entitled items.
  430. allocationMethod: DiscountApplicationAllocationMethod!
  431. # The string identifying the discount code that was used at the time of application.
  432. code: String!
  433. # An ordered index that can be used to identify the discount application and indicate the precedence
  434. # of the discount application for calculations.
  435. index: Int!
  436. # How the discount amount is distributed on the discounted lines.
  437. targetSelection: DiscountApplicationTargetSelection!
  438. # Whether the discount is applied on line items or shipping lines.
  439. targetType: DiscountApplicationTargetType!
  440. # The value of the discount application.
  441. value: PricingValue!
  442. }
  443. # Manual discount applications capture the intentions of a discount that was manually created for an order.
  444. #
  445. # Discount applications don't represent the actual final amount discounted on a line (line item or shipping line).
  446. # The actual amount discounted on a line is represented by the DiscountAllocation object.
  447. type ManualDiscountApplication implements DiscountApplication {
  448. # The method by which the discount's value is applied to its entitled items.
  449. allocationMethod: DiscountApplicationAllocationMethod!
  450. # The description of the discount application.
  451. description: String
  452. # An ordered index that can be used to identify the discount application and indicate the precedence
  453. # of the discount application for calculations.
  454. index: Int!
  455. # How the discount amount is distributed on the discounted lines.
  456. targetSelection: DiscountApplicationTargetSelection!
  457. # Whether the discount is applied on line items or shipping lines.
  458. targetType: DiscountApplicationTargetType!
  459. # The title of the discount application.
  460. title: String!
  461. # The value of the discount application.
  462. value: PricingValue!
  463. }
  464. # Script discount applications capture the intentions of a discount that
  465. # was created by a Shopify Script for an order's line item or shipping line.
  466. #
  467. # Discount applications don't represent the actual final amount discounted on a line (line item or shipping line).
  468. # The actual amount discounted on a line is represented by the DiscountAllocation object.
  469. type ScriptDiscountApplication implements DiscountApplication {
  470. # The method by which the discount's value is applied to its entitled items.
  471. allocationMethod: DiscountApplicationAllocationMethod!
  472. # An ordered index that can be used to identify the discount application and indicate the precedence
  473. # of the discount application for calculations.
  474. index: Int!
  475. # How the discount amount is distributed on the discounted lines.
  476. targetSelection: DiscountApplicationTargetSelection!
  477. # Whether the discount is applied on line items or shipping lines.
  478. targetType: DiscountApplicationTargetType!
  479. # The title of the application as defined by the Script.
  480. title: String!
  481. # The value of the discount application.
  482. value: PricingValue!
  483. }
  484. # An auto-generated type for paginating through multiple Sales.
  485. type SaleConnection {
  486. # A list of edges.
  487. edges: [SaleEdge!]!
  488. # A list of the nodes contained in SaleEdge.
  489. nodes: [Sale!]!
  490. # Information to aid in pagination.
  491. pageInfo: PageInfo!
  492. }
  493. # An auto-generated type which holds one Sale and a cursor during pagination.
  494. type SaleEdge {
  495. # A cursor for use in pagination.
  496. cursor: String!
  497. # The item at the end of SaleEdge.
  498. node: Sale!
  499. }
  500. # An auto-generated type for paginating through multiple AppSubscriptions.
  501. type AppSubscriptionConnection {
  502. # A list of edges.
  503. edges: [AppSubscriptionEdge!]!
  504. # A list of the nodes contained in AppSubscriptionEdge.
  505. nodes: [AppSubscription!]!
  506. # Information to aid in pagination.
  507. pageInfo: PageInfo!
  508. }
  509. # An auto-generated type which holds one AppSubscription and a cursor during pagination.
  510. type AppSubscriptionEdge {
  511. # A cursor for use in pagination.
  512. cursor: String!
  513. # The item at the end of AppSubscriptionEdge.
  514. node: AppSubscription!
  515. }
  516. # An auto-generated type for paginating through multiple AppCredits.
  517. type AppCreditConnection {
  518. # A list of edges.
  519. edges: [AppCreditEdge!]!
  520. # A list of the nodes contained in AppCreditEdge.
  521. nodes: [AppCredit!]!
  522. # Information to aid in pagination.
  523. pageInfo: PageInfo!
  524. }
  525. # An auto-generated type which holds one AppCredit and a cursor during pagination.
  526. type AppCreditEdge {
  527. # A cursor for use in pagination.
  528. cursor: String!
  529. # The item at the end of AppCreditEdge.
  530. node: AppCredit!
  531. }
  532. # An auto-generated type for paginating through multiple Apps.
  533. type AppConnection {
  534. # A list of edges.
  535. edges: [AppEdge!]!
  536. # A list of the nodes contained in AppEdge.
  537. nodes: [App!]!
  538. # Information to aid in pagination.
  539. pageInfo: PageInfo!
  540. }
  541. # An auto-generated type which holds one App and a cursor during pagination.
  542. type AppEdge {
  543. # A cursor for use in pagination.
  544. cursor: String!
  545. # The item at the end of AppEdge.
  546. node: App!
  547. }
  548. # An auto-generated type for paginating through multiple CurrencySettings.
  549. type CurrencySettingConnection {
  550. # A list of edges.
  551. edges: [CurrencySettingEdge!]!
  552. # A list of the nodes contained in CurrencySettingEdge.
  553. nodes: [CurrencySetting!]!
  554. # Information to aid in pagination.
  555. pageInfo: PageInfo!
  556. }
  557. # An auto-generated type which holds one CurrencySetting and a cursor during pagination.
  558. type CurrencySettingEdge {
  559. # A cursor for use in pagination.
  560. cursor: String!
  561. # The item at the end of CurrencySettingEdge.
  562. node: CurrencySetting!
  563. }
  564. # An auto-generated type for paginating through multiple SalesAgreements.
  565. type SalesAgreementConnection {
  566. # A list of edges.
  567. edges: [SalesAgreementEdge!]!
  568. # A list of the nodes contained in SalesAgreementEdge.
  569. nodes: [SalesAgreement!]!
  570. # Information to aid in pagination.
  571. pageInfo: PageInfo!
  572. }
  573. # An auto-generated type which holds one SalesAgreement and a cursor during pagination.
  574. type SalesAgreementEdge {
  575. # A cursor for use in pagination.
  576. cursor: String!
  577. # The item at the end of SalesAgreementEdge.
  578. node: SalesAgreement!
  579. }
  580. # An auto-generated type for paginating through multiple DiscountApplications.
  581. type DiscountApplicationConnection {
  582. # A list of edges.
  583. edges: [DiscountApplicationEdge!]!
  584. # A list of the nodes contained in DiscountApplicationEdge.
  585. nodes: [DiscountApplication!]!
  586. # Information to aid in pagination.
  587. pageInfo: PageInfo!
  588. }
  589. # An auto-generated type which holds one DiscountApplication and a cursor during pagination.
  590. type DiscountApplicationEdge {
  591. # A cursor for use in pagination.
  592. cursor: String!
  593. # The item at the end of DiscountApplicationEdge.
  594. node: DiscountApplication!
  595. }