What tax are we not reclaiming, and why: with a total per commodity
GET
/v1/entities/{entity_id}/unrecovered-tax
const url = 'https://example.com/v1/entities/example/unrecovered-tax?state=unrecovered';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://example.com/v1/entities/example/unrecovered-tax?state=unrecovered'List unrecovered-tax records in one state, with a total per commodity. Defaults to unrecovered.
totals is per commodity and never summed across commodities: two currencies are two answers. The
from/to filters apply to the entry date.
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”entity_id
required
Entity Id
The entity this path is relative to
string
The entity this path is relative to
Query Parameters
Section titled “Query Parameters”Responses
Section titled “Responses”Successful Response
Media typeapplication/json
UnrecoveredPage
object
entity_id
required
Entity Id
string
legal_name
required
Legal Name
string
base_currency
required
Base Currency
string
snapshot_seq
required
Snapshot Seq
integer
items
required
Items
Array<object>
UnrecoveredItemobject
record
required
UnrecoveredRecord
object
id
required
Id
string
entry_id
required
Entry Id
string
commodity
required
Commodity
string
amount_micros
required
Amount Micros
Signed integer micro-units (millionths) as a base-10 string; never a JSON number.
string
state
required
State
Unrecovered | recovered | forgone
string
reason
required
Reason
string
created_at
required
Created At
string
created_by
required
Created By
string
entry
required
Entry
object
id
required
Id
string
dt
required
Dt
string
narration
required
Narration
string
status
required
Status
string
origin
required
Origin
string
version
required
Version
integer
code
required
Code
string
comment
required
Comment
string
tags
required
Tags
Array<Array<string>>
created_at
required
Created At
string
created_by
required
Created By
string
postings
required
Postings
Array<object>
Postingobject
id
required
Id
string
seq
required
Seq
integer
account_id
required
Account Id
string
account_path
required
Account Path
string
commodity
required
Commodity
string
amount_micros
required
Amount Micros
Signed integer micro-units (millionths) as a base-10 string; never a JSON number.
string
links
required
Links
object
key
additional properties
string
links
required
Links
object
key
additional properties
string
state
required
State
string
totals
required
Totals
Per commodity, never summed across them
object
key
additional properties
string
Example
{ "items": [ { "record": { "amount_micros": "-12000000" }, "entry": { "postings": [ { "amount_micros": "-12000000" } ] } } ]}Bad Request
Media typeapplication/json
ErrorEnvelope
object
Example generated
{ "error": { "code": "example", "message": "example", "retryable": true, "details": [ {} ], "request_id": "example", "next_action": {} }}Unauthorized
Media typeapplication/json
ErrorEnvelope
object
Example generated
{ "error": { "code": "example", "message": "example", "retryable": true, "details": [ {} ], "request_id": "example", "next_action": {} }}Forbidden
Media typeapplication/json
ErrorEnvelope
object
Example generated
{ "error": { "code": "example", "message": "example", "retryable": true, "details": [ {} ], "request_id": "example", "next_action": {} }}Not Found
Media typeapplication/json
ErrorEnvelope
object
Example generated
{ "error": { "code": "example", "message": "example", "retryable": true, "details": [ {} ], "request_id": "example", "next_action": {} }}Conflict
Media typeapplication/json
ErrorEnvelope
object
Example generated
{ "error": { "code": "example", "message": "example", "retryable": true, "details": [ {} ], "request_id": "example", "next_action": {} }}Precondition Failed
Media typeapplication/json
ErrorEnvelope
object
Example generated
{ "error": { "code": "example", "message": "example", "retryable": true, "details": [ {} ], "request_id": "example", "next_action": {} }}Unprocessable Content
Media typeapplication/json
ErrorEnvelope
object
Example generated
{ "error": { "code": "example", "message": "example", "retryable": true, "details": [ {} ], "request_id": "example", "next_action": {} }}Internal Server Error
Media typeapplication/json
ErrorEnvelope
object
Example generated
{ "error": { "code": "example", "message": "example", "retryable": true, "details": [ {} ], "request_id": "example", "next_action": {} }}Service Unavailable
Media typeapplication/json
ErrorEnvelope
object
Example generated
{ "error": { "code": "example", "message": "example", "retryable": true, "details": [ {} ], "request_id": "example", "next_action": {} }}