write_themes_assets access needed but it does not exist

Topic summary

Access to themeFilesUpsert (Admin GraphQL API 2024-10) is blocked by an undocumented permission: write_themes_assets. Developers already have read_themes/write_themes, but the mutation returns “Access denied… write_themes and write_themes_assets,” and app setup flags write_themes_assets as an invalid scope. This is disrupting migrations from the deprecated REST Admin API and could force merchants to re-consent to new scopes.

Key points:

  • The required scope write_themes_assets is not documented and cannot be selected in app configuration, causing deploy/build failures and API errors (multiple confirmations, screenshots).
  • Concern that write_themes_assets should be a sub-scope of write_themes to avoid re-permission friction.

Workarounds/updates:

  • Since 2024-04, public apps can request gated scopes via a Google form (link shared). One developer reports approval restored access; note approvals are app-specific, so new apps require reapplying.
  • Others report the form hasn’t resolved access yet.
  • A developer claims to have it working and shared a step-by-step write-up (external link).

Status: Mostly unresolved/ongoing. Action items: apply for the gated scope via the form per app, and review the shared implementation guide. Await official documentation/rollout from Shopify.

Summarized with AI on December 12. AI used: gpt-5.

Hello I already have the read_themes and write_themes access but when running this mutation (themeFilesUpsert) with the latest API (2024-10) : https://shopify.dev/docs/api/admin-graphql/2024-10/mutations/themeFilesUpsert

`#graphql
      mutation themeFilesUpsert($files: [OnlineStoreThemeFilesUpsertFileInput!]!, $themeId: ID!) {
        themeFilesUpsert(files: $files, themeId: $themeId) {
          job {
            done
          }
          upsertedThemeFiles {
            filename
          }
          userErrors {
            field
            message
          }
        }
      }
`

I get this error message:

Access denied for themeFilesUpsert field. Required access: The user must have write_themes and write_themes_assets.

But the problem is write_themes_assets seems to not exist I have checked online and Shopify never mentions it…

And I’m having this error when trying to run app deploy script:

9 Likes

I encountered the same issue and hope Shopify can provide a solution.

3 Likes

Also facing the same problem. Rest api is deprecated and i am forced to use this mutation but unfortunately can not.

2 Likes

I have the same issue. write_themes_assets should be a sub-scope of write_themes. This is going to create a terrible user experience for existing apps forced to migrate from the REST Admin API to the GraphQL Admin API, as storeowners are going to have to re-permission the app because we’ll need to request new scopes. It’s also frustrating that the scopes haven’t been rolled out properly:

These scopes are invalid - [write_themes_assets]

Please can we see more of a joined-up approach within Shopify, so where different teams are responsible for different aspects of a mandated policy, they work together to ensure that developers aren’t left stuck in the middle?

3 Likes

Same issue here! Hoping for a solution soon.

2 Likes

Same issue.

2 Likes

Same issue here.
I have come to believe that Shopify hates its developers. Constantly changing the API and its tools, deprecating a tool suddenly, and now THIS!

It takes a lot of patience to develop an app for Shopify.

4 Likes

I’m encountering the same issue and am stuck in my development process.

Same issue, I started few days ago to develop my first app and encountered in this mistake

Same here, what was that?

For anyone who faced this issue, I found out that since 2024/04 Apps with public distribution should apply for specific access scopes from this form:
https://docs.google.com/forms/d/e/1FAIpQLSfZTB1vxFC5d1-GPdqYunWRGUoDcOheHQzfK2RoEFEHrknt5g/viewform

I hope this helps you.

1 Like

I submitted it, and it was approved. Later, I deleted the app and created a new one, but I don’t think that’s the issue

Well, they approved the access scopes for the app you have applied for. When you create a new one it shouldn’t have the access scopes because you mention your app name in the form.

So I guess you should apply for your new app as well.

1 Like

There are some other threads about this on the dev forum: https://community.shopify.dev/t/add-liquid-file-to-the-live-shopify-theme/719

Apparently, there is this form that you can fill out to request access, but it doesn’t seem like anyone’s really had this solve their problem so far: https://community.shopify.dev/t/issue-with-write-themes-and-write-themes-assets-scopes-in-graphql-api/633/5

I have this working and I’ve documented the solution here:

https://www.linkedin.com/pulse/so-you-want-use-writethemesassets-shopify-graphql-api-naughtyduk-8jkfe/