RestAPI create a new payment return error code 404

Topic summary

Main issue: Creating a payment via the Admin REST Payment endpoint for a checkout token returns 404 Not Found, including when using the Shopify SDK.

Cause: These payment resources are restricted to approved Sales Channel apps. Access requires applying for and being granted Sales Channel API approval; simply toggling “Payment processing” is not sufficient without approval.

Workaround for testing: Use the Storefront API (GraphQL) to simulate checkout and payment flows:

  • checkoutCreate to build a test checkout.
  • checkoutCompleteFree to simulate a completed (free) payment.
    This is acknowledged as a less-than-ideal substitute; feedback will be passed to the team.

Actions/decisions:

  • To use the Admin payment endpoint, apply for Sales Channel access following Shopify’s requirements.
  • For immediate testing without approval, use the Storefront API mutations above.

Status: Effectively resolved with explanation and workaround; no direct fix for 404 without Sales Channel approval. Unanswered only in that approval cannot be guaranteed.

Summarized with AI on February 2. AI used: gpt-5.

I want to test create payment with RestAPI, but when I use the api at document (https://shopify.dev/api/admin-rest/2023-01/resources/payment#post-checkouts-token-payments) I get response 404 Not Found. I try with SDK (

new shopify.rest.Payment({session})) and have same response.

I searched this issue, I found that I have to turn on Sales Channel => Payment processing. Is it really necessary here? Because i only want test function but need Shopify review??

Hey @trendiitest - thanks for getting in touch. At the moment, these payment resources are restricted to Sales Channels only, and you must apply for approval to access the resources. There is a bit more information here, but the approval process is in place as there are certain requirements that are needed to be approved for access to the Sales Channel API.

That said, if you did want to test checkout functionality, you could make use of the Storefront API’s Checkout object through GraphQL. You could use the CheckoutCreate mutation to set up a test checkout and then use the CheckoutCompleteFree mutation to simulate a completed payment. It’s not the most ideal workaround, so I’m happy to send your feedback on to our team as well.

I can’t guarantee anything in terms of approval for the access scopes, but I do get where you’re coming from - it would be useful to be able to test the functionality, especially if you’re building a development store or an app to test infrastructure.

Hope this helps - let us know if we can clarify anything further for you.

1 Like