POST https://sandbox.payme.io/api/public/expensesPOST https://live.payme.io/api/public/expensesNo credentials are documented for this endpoint.
Upload an expense document for a seller via a publicly accessible file URL.
Seller identification: Exactly one method must be used per request:
sellerId (UUID)socialId + emailProviding both or neither returns HTTP 400.
Supported file formats: PDF, JPG, PNG.
This endpoint takes no path, query or header parameters.
Content type: application/json
| Field | Type | Required | Description |
|---|---|---|---|
sellerId |
string | no | Seller UUID (use this OR socialId + email, not both) |
socialId |
string | no | Seller social/business ID number (must be paired with email) |
email |
string | no | Seller email address (must be paired with socialId) |
file |
string | yes | Publicly accessible URL of the expense document (PDF, JPG, or PNG) |
{
"sellerId": "a6a9700f-8571-4f9b-bfae-ba943fb96982",
"file": "https://i0.wp.com/avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/AK-3.png?ssl=1"
}
curl -X POST 'https://sandbox.payme.io/api/public/expenses' \
-H 'Content-Type: application/json' \
--data-raw '{
"sellerId": "a6a9700f-8571-4f9b-bfae-ba943fb96982",
"file": "https://i0.wp.com/avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/AK-3.png?ssl=1"
}'
const response = await fetch("https://sandbox.payme.io/api/public/expenses", {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify({
"sellerId": "a6a9700f-8571-4f9b-bfae-ba943fb96982",
"file": "https://i0.wp.com/avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/AK-3.png?ssl=1"
}),
});
console.log(await response.text());
import requests
response = requests.post(
"https://sandbox.payme.io/api/public/expenses",
json={
"sellerId": "a6a9700f-8571-4f9b-bfae-ba943fb96982",
"file": "https://i0.wp.com/avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/AK-3.png?ssl=1",
},
)
print(response.text)
<?php
$body = <<<'BODY'
{
"sellerId": "a6a9700f-8571-4f9b-bfae-ba943fb96982",
"file": "https://i0.wp.com/avatar-management--avatars.us-west-2.prod.public.atl-paas.net/initials/AK-3.png?ssl=1"
}
BODY;
$ch = curl_init('https://sandbox.payme.io/api/public/expenses');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => $body,
]);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
| Field | Type | Description |
|---|---|---|
payload |
object | |
payload.id |
string | Unique identifier for the created expense record |
payload.capturedDate |
string | Timestamp when the expense was captured |
payload.sellerId |
string | Resolved seller UUID |
{
"payload": {
"id": "a3504d9d-c187-48a0-8274-bea3b48e5663",
"capturedDate": "2026-02-02T13:05:54.170Z",
"sellerId": "a6a9700f-8571-4f9b-bfae-ba943fb96982"
}
}
| Field | Type | Description |
|---|---|---|
statusCode |
integer | HTTP status code |
message |
string | Error message(s) |
error |
string | Error type |
{
"statusCode": 400,
"message": [
"socialId must be a number conforming to the specified constraints",
"socialId should not be empty",
"email must be an email",
"email should not be empty",
"sellerId must be a UUID",
"sellerId should not be empty"
],
"error": "Bad Request"
}
| Field | Type | Description |
|---|---|---|
error |
string | |
error_description |
string |
{
"error": "unauthorized_client",
"error_description": "Client authentication failed"
}
| Field | Type | Description |
|---|---|---|
statusCode |
integer | HTTP status code |
message |
string | Error message(s) |
error |
string | Error type |
{
"statusCode": 422,
"message": "Could not resolve seller",
"error": "Unprocessable Entity"
}