Resolved: Updating fieldset always fails: INVALID_ENDPOINT

Hi,

I’m trying to update a fieldset through a migration but it always fails.

Failed request:

PUT https://site-api.datocms.com/fieldset/31861

content-type: application/json
accept: application/json
authorization: Bearer [redacted]
user-agent: js-client v3.2.0
X-Api-Version: 3
X-Environment: floris-tenhove--local--feature-ch10036

{"data":{"id":"31861","type":"fieldset","attributes":{"title":"🏷 Topic Title & Description","hint":"Shown on the left in the list of topics."}}}

Error:

{"data":[{"id":"cf3acb","type":"api_error","attributes":{"code":"INVALID_ENDPOINT","details":{}}}]}

I’m using the JS client and the client.fieldsets.update method. I first fetch the ID of the fieldset and pass it to the update method.

Any help is appreciated!

Hi @floris.tenhove :slight_smile:

Pretty strange! The URL should be https://site-api.datocms.com/fieldsets/31861, not https://site-api.datocms.com/fieldset/31861 (plural form, REST convention).

I’m gonna try it :slight_smile:

Yeppp it’s a bug. Gonna deploy a fix soon :slight_smile:

Thank you!

1 Like

@floris.tenhove try again please!

It works now, thanks for your quick reply and fix! :slight_smile: