# POST Attachment/{uuid}.file returning 400 "Invalid data format supplied in request body" since ~7 July — documented format rejected

**URL:** <https://community.servicem8.com/t/post-attachment-uuid-file-returning-400-invalid-data-format-supplied-in-request-body-since-7-july-documented-format-rejected/1134>\
**Category:** API & SDK\
**Created:** [July 8, 2026, 2:55am UTC](https://community.servicem8.com/t/post-attachment-uuid-file-returning-400-invalid-data-format-supplied-in-request-body-since-7-july-documented-format-rejected/1134 "2026-07-08T02:55:45Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![alps\_i\_t\_partner\_sup](https://avatars.discourse-cdn.com/v4/letter/a/a9adbd/32.png) [@alps\_i\_t\_partner\_sup](https://community.servicem8.com/u/alps_i_t_partner_sup)\
**Post date:** [July 8, 2026, 2:55am UTC](https://community.servicem8.com/t/post-attachment-uuid-file-returning-400-invalid-data-format-supplied-in-request-body-since-7-july-documented-format-rejected/1134/1 "2026-07-08T02:55:45Z")

</div>

Since approximately 7 July 2026, all POST requests to `https://api.servicem8.com/api_1.0/Attachment/{uuid}.file` return:

```auto
{"errorCode":400,"message":"Invalid data format supplied in request body","documentation":"Please refer to https://developer.servicem8.com/llms.txt for developer documentation."}

```

We note the error response uses a new `errorCode`/`message` schema and references llms.txt, and the “Create a new Attachment” reference page was updated roughly a week before this began — which suggests a recent validation-layer rollout may have affected the `.file` endpoint.

Could you please confirm:

1. Has the expected request format for `POST Attachment/{uuid}.file` changed? If so, what is the correct format now?
2. If not, can this be escalated as a regression? It currently breaks file uploads following your own documented example.

Happy to provide additional request traces if useful.

Thanks,  
Melvic

---

<div class="post-metadata">

**Author:** ![Cody](https://sea2.discourse-cdn.com/flex002/user_avatar/community.servicem8.com/cody/32/52_2.png) [@Cody](https://community.servicem8.com/u/Cody)\
**Post date:** [July 11, 2026, 2:57am UTC](https://community.servicem8.com/t/post-attachment-uuid-file-returning-400-invalid-data-format-supplied-in-request-body-since-7-july-documented-format-rejected/1134/2 "2026-07-11T02:57:36Z")

</div>

Hi ALPS I.T.,

The documented attachment upload flow is still to create the Attachment record first, then upload the file data to `POST https://api.servicem8.com/api_1.0/Attachment/{attachment_uuid}.file` using the UUID returned in the `x-record-uuid` header.

For the Attachment record, `related_object` should be set to `job`, `related_object_uuid` should be the job UUID, and `file_type` should match the file extension including the leading full stop, for example `.pdf`.

For the `.file` request, the documented example posts to `/Attachment/{uuid}.file` and supplies the file as the `file` field using `CurlFile`.

The Attachment create endpoint requires the `manage_attachments` OAuth scope when using OAuth.

If requests matching that format are consistently returning `400 Invalid data format supplied in request body`, that’s something we’ll need to investigate from our side rather than continue troubleshooting publicly.

Please email [support@servicem8.com](mailto:support@servicem8.com) with a reproducible cURL example, the affected attachment UUID returned in `x-record-uuid`, the full response status/headers/body, and a timestamp with timezone so we can trace it.

Thanks,  
Cody
