Tell me the endpoint or GraphQL to upload image files in a location File under Content

Topic summary

A user is seeking the correct API endpoint or GraphQL mutation to upload image files to Shopify’s Files section under Content.

Initial Attempt:

  • The user consulted an AI assistant (Claude) which suggested using a REST Admin API endpoint
  • The suggested endpoint (POST /admin/api/2023-10/themes/<theme_id>/assets.json) did not work

Solution Provided:

  • Another user recommended using the FileCreate mutation in Shopify’s GraphQL Admin API
  • A link to the official documentation was shared for reference

Status: The discussion appears resolved with the GraphQL mutation being the correct approach for uploading files to Shopify’s Content Files section.

Summarized with AI on November 13. AI used: claude-sonnet-4-5-20250929.

I’m trying to find out how to upload image files on Files under content using API or GraphQL.

I asked Claunde2 and it says;

To upload an image file to the Files section in Shopify using the REST Admin API, you would use the following endpoint:

POST /admin/api/2023-10/themes/<theme_id>/assets.json

But it didn’t work.

Please tell me endpoint or GraphQL to do.

Thanks.

Hey @heyuuuuu

You’ll want to use the FileCreate mutation to add files here.

1 Like