GraphQL Billing questions to client experience

Solved
Highlighted
Shopify Partner
7 0 0

Hi guys,

 

just to said I went and read all the following:

https://www.shopify.com/partners/blog/shopify-app-billing-cycle

https://shopify.dev/tutorials/bill-for-your-app-using-graphql-admin-api

https://www.shopify.com/partners/blog/billing-api-graphql

 

but I was not able to answer, yet some of the questions that I have. Given that we are building app in react and node and want to start using GraphQL. We plan to use do use subscription base plans, but use pay-as-you-go model. 

 

we have a few questions over billing API:

1. In https://shopify.dev/tutorials/bill-for-your-app-using-graphql-admin-api - in the flow "How billing works with the GraphQL Admin API" is not clear if shop owner need to complete this process once (on for subscription to start), or we need to push store owner verify every charge?

 

2. Do we need for each usage charge to issue it right a way to billing, or we can process them in batch and add them lets say once every 24h? As far as I understand we need to use this: https://shopify.dev/docs/admin-api/graphql/reference/mutation/input-object/appusagepricinginput to do so.

 

Two other questions, not related to billing:

1. We understand from here https://shopify.dev/docs/admin-api/graphql/reference/object/shop/ we can colloct store information  - but is there a way to take store logo?

2. We want our app to expose a page to store clients like "shop-url.myshopify.com/page-X" or "custom-domain.com/page-X"

 

Thanks for all the help! If you can point me in the right direction where I can read more will also be appreciated.

0 Likes
Highlighted
Shopify Staff (Retired)
Shopify Staff (Retired)
624 102 127

This is an accepted solution.

Hey @sstankov 

 

You said on your post "We plan to use do use subscription base plans, but use pay-as-you-go model. " - This is not very clear. Are you using a subscription model, or a pay-as-you-go model? These are two very different concepts

 

To answer your Billing questions first:

 

1) If you are using the Subscription Model, then the merchant just needs to accept the Recurring Application Charge (aka the App Subscription charge) one time only. After that, the merchant will be billed on their next 30 day billing cycle without them needing to do any action. You can also add Usage Charges on top of the Recurring Application Charge/AppSubscription up to the value of the capped amount, without requiring approval as well

 

If you go with a Pay As You Go Model, then yes, you will need the merchant to approve every single charge you create with the appPurchaseOneTimeCreate mutation

 

2) You should charge and bill Usage Charges immediately.

 

For your other questions:

1) As of right now you cannot do this with the Shopify GraphQL API. However you can do this via the REST Admin API, using the "assets" endpoint: https://shopify.dev/docs/admin-api/rest/reference/online-store/asset

2) To do this you need to use an application proxy: https://shopify.dev/tutorials/display-data-on-an-online-store-with-an-application-proxy-app-extensio... and https://medium.com/shop-sheriff/what-is-a-shopify-application-proxy-and-how-can-i-use-it-153bf99d1a9...

 

 

 

Hassain | Developer Support Specialist @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 

1 Like
Shopify Partner
7 0 0

Thanks for the information @hassain !!!!

0 Likes