Update manual asset
curl --request PATCH \
--url https://api.entendre.finance/v1/assets/{asset_id} \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"ledger_account_id": "lac_507f1f77bcf86cd799439011",
"cost_basis": "100.00",
"quantity": "100.00",
"legal_entity_id": "le_507f1f77bcf86cd799439011"
}
'const options = {
method: 'PATCH',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
ledger_account_id: 'lac_507f1f77bcf86cd799439011',
cost_basis: '100.00',
quantity: '100.00',
legal_entity_id: 'le_507f1f77bcf86cd799439011'
})
};
fetch('https://api.entendre.finance/v1/assets/{asset_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.entendre.finance/v1/assets/{asset_id}"
payload = {
"ledger_account_id": "lac_507f1f77bcf86cd799439011",
"cost_basis": "100.00",
"quantity": "100.00",
"legal_entity_id": "le_507f1f77bcf86cd799439011"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"data": {
"id": "ast_abc123",
"asset_type": "ETH",
"quantity": "100.00",
"remaining_quantity": "100.00",
"cost_basis": "100.00",
"currency": "USD",
"date_received": null,
"chain": null,
"legal_entity_id": "le_507f1f77bcf86cd799439011",
"ledger_account_id": "lac_507f1f77bcf86cd799439011",
"transaction_id": null,
"source_id": null,
"is_manual": true,
"created_at": null,
"updated_at": null
}
}{
"error": {
"code": "VALIDATION_ERROR",
"message": "Invalid path, query or request body.",
"request_id": "req_example"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "Authentication is required.",
"request_id": "req_example"
}
}{
"error": {
"code": "FORBIDDEN",
"message": "Insufficient access to organization",
"request_id": "req_example"
}
}{
"error": {
"code": "RESOURCE_NOT_FOUND",
"message": "Resource not found",
"request_id": "req_example"
}
}{
"error": {
"code": "CONFLICT",
"message": "The resource state does not allow this operation.",
"request_id": "req_example"
}
}{
"error": {
"code": "RATE_LIMITED",
"message": "Rate limit exceeded. Retry after 30s.",
"request_id": "req_example"
}
}{
"error": {
"code": "INTERNAL_ERROR",
"message": "Internal server error",
"request_id": "req_example"
}
}{
"error": {
"code": "SERVICE_UNAVAILABLE",
"message": "Service unavailable.",
"request_id": "req_example"
}
}Assets
Update manual asset
Updates a manual asset and adjusts its balances. Imported assets cannot be edited.
PATCH
/
v1
/
assets
/
{asset_id}
Update manual asset
curl --request PATCH \
--url https://api.entendre.finance/v1/assets/{asset_id} \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"ledger_account_id": "lac_507f1f77bcf86cd799439011",
"cost_basis": "100.00",
"quantity": "100.00",
"legal_entity_id": "le_507f1f77bcf86cd799439011"
}
'const options = {
method: 'PATCH',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
ledger_account_id: 'lac_507f1f77bcf86cd799439011',
cost_basis: '100.00',
quantity: '100.00',
legal_entity_id: 'le_507f1f77bcf86cd799439011'
})
};
fetch('https://api.entendre.finance/v1/assets/{asset_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.entendre.finance/v1/assets/{asset_id}"
payload = {
"ledger_account_id": "lac_507f1f77bcf86cd799439011",
"cost_basis": "100.00",
"quantity": "100.00",
"legal_entity_id": "le_507f1f77bcf86cd799439011"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"data": {
"id": "ast_abc123",
"asset_type": "ETH",
"quantity": "100.00",
"remaining_quantity": "100.00",
"cost_basis": "100.00",
"currency": "USD",
"date_received": null,
"chain": null,
"legal_entity_id": "le_507f1f77bcf86cd799439011",
"ledger_account_id": "lac_507f1f77bcf86cd799439011",
"transaction_id": null,
"source_id": null,
"is_manual": true,
"created_at": null,
"updated_at": null
}
}{
"error": {
"code": "VALIDATION_ERROR",
"message": "Invalid path, query or request body.",
"request_id": "req_example"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "Authentication is required.",
"request_id": "req_example"
}
}{
"error": {
"code": "FORBIDDEN",
"message": "Insufficient access to organization",
"request_id": "req_example"
}
}{
"error": {
"code": "RESOURCE_NOT_FOUND",
"message": "Resource not found",
"request_id": "req_example"
}
}{
"error": {
"code": "CONFLICT",
"message": "The resource state does not allow this operation.",
"request_id": "req_example"
}
}{
"error": {
"code": "RATE_LIMITED",
"message": "Rate limit exceeded. Retry after 30s.",
"request_id": "req_example"
}
}{
"error": {
"code": "INTERNAL_ERROR",
"message": "Internal server error",
"request_id": "req_example"
}
}{
"error": {
"code": "SERVICE_UNAVAILABLE",
"message": "Service unavailable.",
"request_id": "req_example"
}
}Authorizations
Your organization API key. Some operations also need a key that is associated with a user; their pages say so.
Path Parameters
ID of the asset.
Minimum string length:
1Body
application/json
Response
The request succeeded.
Show child attributes
Show child attributes