> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://docs.mangopay.com/api-reference/settlements/upload-settlement-file/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.mangopay.com/_mcp/server. # Upload a settlement file to the secure URL PUT %7BSettlementFileUploadUrl%7D/{SettlementFileUploadUrl} Content-Type: text/csv To send your CSV settlement file to Mangopay, use the `SettlementFileUploadUrl` value dynamically returned by [POST Create a Settlement and generate upload URL](/api-reference/settlements/create-settlement) endpoint. **Caution – Use settlement file example as template** You must follow the [specifications provided here](/api-reference/settlements/settlement-file). Use this Example\_Mangopay\_Settlement\_File.csv, which contains the correct column and row labels and example data for 3 transactions. Remove the example data lines before generating your own file. You need to send one file per currency, as soon as it becomes available. Read more about [providing settlement files to Mangopay](/guides/echo#send-settlement-files-to-mangopay). When calling the pre-signed `SettlementFileUploadUrl`: * Ensure you integrate the full URL (host, path, queries) dynamically as it is unique to each file upload attempt * Don't include the Authorization header, as the URL is already authenticated in the query strings * Set the `Content-Type` header to `text/csv` and send the file as a raw binary stream using `data-binary` Note that the `FileName` used by Mangopay is the one you sent on the [POST Create a Settlement and generate upload URL](/api-reference/settlements/create-settlement) endpoint (with a timestamp automatically appended); the name of the file on your system is only relevant for the `data-binary` stream in this call. Reference: https://docs.mangopay.com/api-reference/settlements/upload-settlement-file ## Authentication - `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer `, where token is your auth token. If your platform is using a [proxy](/guides/sca/proxy-management) to take SCA-triggering action on behalf of users, you also need to integrate [mTLS authentication](/guides/sca/platform) and use the `api-mtls` base URL. ## Request ### Path parameters - `SettlementFileUploadUrl` (string, required) — The variable URL is only documented as a path parameter on this path for documentation reasons. I allows it to be rendered visiablly on the page, and because there are two dynamic server URLs in the spec (so both would be on the / path). The variable URL is the server for this request, and it has a variable host and path and query parameters. You do not need to add anything to it. ### Body (text/csv) This endpoint expects a string. - `string` ## Response ### 200 No response body. A 200 response indicates that the file was uploaded successfully. ## Examples **Request** ```json "string" ``` **Response** ```json {} ```