Currency Rates
Part of the Support API. Base URL https://your-domain.com/admin/api/v1 — replace the host with your own installation and the token placeholder with a real Bearer token (see Authentication).
List currency rates
GET/admin/api/v1/support/currencies/{currency_id}/ratesRetrieve a paginated list of currency rates for a specific currency with filtering and sorting
🔒 Requires a valid Bearer token.
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
currency_id | integer | Yes | The currency ID |
Query parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
include | string | No | Comma-separated list of relationships to include. Available options: company, creator | currency |
filter[id] | string | No | Comma-separated list of IDs to filter by | |
filter[company_id] | string | No | Comma-separated list of company IDs to filter by | |
filter[name] | string | No | Filter by rate date (YYYY-MM-DD) | |
sort | string | Yes | Sort field | name |
page | integer | Yes | Page number | 1 |
curl -X GET "https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates?include=currency&sort=name&page=1" \
-H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
-H "Accept: application/json" \
-H "Content-Type: application/json"const response = await fetch("https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates?include=currency&sort=name&page=1", {
method: "GET",
headers: {
"Authorization": "Bearer {YOUR_AUTH_TOKEN}",
"Accept": "application/json",
"Content-Type": "application/json",
},
});
const data = await response.json();
console.log(data);<?php
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates?include=currency&sort=name&page=1', [
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
'Accept' => 'application/json',
'Content-Type' => 'application/json',
],
]);
$data = json_decode($response->getBody(), true);import requests
url = "https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates?include=currency&sort=name&page=1"
headers = {
"Authorization": "Bearer {YOUR_AUTH_TOKEN}",
"Accept": "application/json",
"Content-Type": "application/json",
}
response = requests.get(url, headers=headers)
data = response.json()
print(data)Example response 200
{
"data": [
{
"id": null,
"name": "1981-05-29T00:00:00.000000Z",
"rate": "1.960500",
"inverse_rate": 0.510073960724305,
"currency_id": 216,
"company_id": 1,
"creator_id": 1,
"created_at": null,
"updated_at": null
},
{
"id": null,
"name": "1981-09-09T00:00:00.000000Z",
"rate": "1.827988",
"inverse_rate": 0.5470495429948118,
"currency_id": 217,
"company_id": 1,
"creator_id": 1,
"created_at": null,
"updated_at": null
}
],
"links": {
"first": "/?page=1",
"last": "/?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Previous",
"page": null,
"active": false
},
{
"url": "/?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Next »",
"page": null,
"active": false
}
],
"path": "/",
"per_page": 10,
"to": 2,
"total": 2
}
}Error response — 401
{
"message": "Unauthenticated."
}Create currency rate
POST/admin/api/v1/support/currencies/{currency_id}/ratesCreate a new currency exchange rate for a specific currency
🔒 Requires a valid Bearer token.
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
currency_id | integer | Yes | The currency ID |
Body parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Rate effective date (YYYY-MM-DD format). Must be a valid date. |
rate | number | Yes | Exchange rate (minimum 0). Must be at least 0. |
company_id | integer | No | Company ID (optional, null for global rates). Must match an existing stored value. |
curl -X POST "https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates" \
-H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"name": "2024-01-15",
"rate": 1.25,
"company_id": 1
}'const response = await fetch("https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates", {
method: "POST",
headers: {
"Authorization": "Bearer {YOUR_AUTH_TOKEN}",
"Accept": "application/json",
"Content-Type": "application/json",
},
body: JSON.stringify({
"name": "2024-01-15",
"rate": 1.25,
"company_id": 1
}),
});
const data = await response.json();
console.log(data);<?php
$client = new \GuzzleHttp\Client();
$response = $client->request('POST', 'https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates', [
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
'Accept' => 'application/json',
'Content-Type' => 'application/json',
],
'json' => [
'name' => '2024-01-15',
'rate' => 1.25,
'company_id' => 1,
],
]);
$data = json_decode($response->getBody(), true);import requests
url = "https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates"
headers = {
"Authorization": "Bearer {YOUR_AUTH_TOKEN}",
"Accept": "application/json",
"Content-Type": "application/json",
}
payload = {
"name": "2024-01-15",
"rate": 1.25,
"company_id": 1,
}
response = requests.post(url, headers=headers, json=payload)
data = response.json()
print(data)Example response 201
{
"data": {
"id": null,
"name": "1996-01-25T00:00:00.000000Z",
"rate": "1.992991",
"inverse_rate": 0.501758412356102,
"currency_id": 218,
"company_id": 1,
"creator_id": 1,
"created_at": null,
"updated_at": null
},
"message": "Currency rate created successfully."
}Error response — 401
{
"message": "Unauthenticated."
}Show currency rate
GET/admin/api/v1/support/currencies/{currency_id}/rates/{id}Retrieve a specific currency rate by its ID
🔒 Requires a valid Bearer token.
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
currency_id | integer | Yes | The currency ID |
id | integer | Yes | The currency rate ID |
Query parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
include | string | No | Comma-separated list of relationships to include. Available options: company, creator | currency |
curl -X GET "https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}?include=currency" \
-H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
-H "Accept: application/json" \
-H "Content-Type: application/json"const response = await fetch("https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}?include=currency", {
method: "GET",
headers: {
"Authorization": "Bearer {YOUR_AUTH_TOKEN}",
"Accept": "application/json",
"Content-Type": "application/json",
},
});
const data = await response.json();
console.log(data);<?php
$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}?include=currency', [
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
'Accept' => 'application/json',
'Content-Type' => 'application/json',
],
]);
$data = json_decode($response->getBody(), true);import requests
url = "https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}?include=currency"
headers = {
"Authorization": "Bearer {YOUR_AUTH_TOKEN}",
"Accept": "application/json",
"Content-Type": "application/json",
}
response = requests.get(url, headers=headers)
data = response.json()
print(data)Example response 200
{
"data": {
"id": null,
"name": "1981-05-29T00:00:00.000000Z",
"rate": "1.960500",
"inverse_rate": 0.510073960724305,
"currency_id": 219,
"company_id": 1,
"creator_id": 1,
"created_at": null,
"updated_at": null
}
}Error response — 401
{
"message": "Unauthenticated."
}Update currency rate
PUT/admin/api/v1/support/currencies/{currency_id}/rates/{id}Update an existing currency rate
🔒 Requires a valid Bearer token.
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
currency_id | integer | Yes | The currency ID |
id | integer | Yes | The currency rate ID |
Body parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | No | Rate effective date (YYYY-MM-DD format). Must be a valid date. |
rate | number | No | Exchange rate (minimum 0). Must be at least 0. |
company_id | integer | No | Company ID (optional, null for global rates). Must match an existing stored value. |
curl -X PUT "https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}" \
-H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"name": "2024-01-15",
"rate": 1.25,
"company_id": 1
}'const response = await fetch("https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}", {
method: "PUT",
headers: {
"Authorization": "Bearer {YOUR_AUTH_TOKEN}",
"Accept": "application/json",
"Content-Type": "application/json",
},
body: JSON.stringify({
"name": "2024-01-15",
"rate": 1.25,
"company_id": 1
}),
});
const data = await response.json();
console.log(data);<?php
$client = new \GuzzleHttp\Client();
$response = $client->request('PUT', 'https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}', [
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
'Accept' => 'application/json',
'Content-Type' => 'application/json',
],
'json' => [
'name' => '2024-01-15',
'rate' => 1.25,
'company_id' => 1,
],
]);
$data = json_decode($response->getBody(), true);import requests
url = "https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}"
headers = {
"Authorization": "Bearer {YOUR_AUTH_TOKEN}",
"Accept": "application/json",
"Content-Type": "application/json",
}
payload = {
"name": "2024-01-15",
"rate": 1.25,
"company_id": 1,
}
response = requests.put(url, headers=headers, json=payload)
data = response.json()
print(data)Example response 200
{
"data": {
"id": null,
"name": "1996-01-25T00:00:00.000000Z",
"rate": "1.992991",
"inverse_rate": 0.501758412356102,
"currency_id": 220,
"company_id": 1,
"creator_id": 1,
"created_at": null,
"updated_at": null
},
"message": "Currency rate updated successfully."
}Error response — 401
{
"message": "Unauthenticated."
}Delete currency rate
DELETE/admin/api/v1/support/currencies/{currency_id}/rates/{id}Delete a currency rate
🔒 Requires a valid Bearer token.
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
currency_id | integer | Yes | The currency ID |
id | integer | Yes | The currency rate ID |
curl -X DELETE "https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}" \
-H "Authorization: Bearer {YOUR_AUTH_TOKEN}" \
-H "Accept: application/json" \
-H "Content-Type: application/json"const response = await fetch("https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}", {
method: "DELETE",
headers: {
"Authorization": "Bearer {YOUR_AUTH_TOKEN}",
"Accept": "application/json",
"Content-Type": "application/json",
},
});
const data = await response.json();
console.log(data);<?php
$client = new \GuzzleHttp\Client();
$response = $client->request('DELETE', 'https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}', [
'headers' => [
'Authorization' => 'Bearer {YOUR_AUTH_TOKEN}',
'Accept' => 'application/json',
'Content-Type' => 'application/json',
],
]);
$data = json_decode($response->getBody(), true);import requests
url = "https://your-domain.com/admin/api/v1/support/currencies/{currency_id}/rates/{id}"
headers = {
"Authorization": "Bearer {YOUR_AUTH_TOKEN}",
"Accept": "application/json",
"Content-Type": "application/json",
}
response = requests.delete(url, headers=headers)
data = response.json()
print(data)Example response 200
{
"message": "Currency rate deleted successfully."
}Error response — 401
{
"message": "Unauthenticated."
}