curl --request GET \
--url https://api.watchdog.no/v1/intake/needs-attention \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.watchdog.no/v1/intake/needs-attention', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.watchdog.no/v1/intake/needs-attention"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text){
"data": [
{
"kind": "import_failed",
"subject_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"occurred_at": "2023-11-07T05:31:56Z",
"handled": {
"at": "2023-11-07T05:31:56Z",
"by": {
"user_id": "<string>",
"name": "<string>"
}
},
"import_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"channel": "peppol",
"integration_name": "<string>",
"file_name": "<string>",
"document_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"reason": "<string>",
"failure_code": "<string>",
"cause": "not_an_invoice",
"owner": "organization",
"invoice": {
"supplier_name": "<string>",
"invoice_number": "<string>",
"total": "<string>",
"currency": "<string>",
"due_date": "2023-12-25"
},
"suggested_invoice": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"invoice_number": "<string>",
"supplier_name": "<string>",
"category": "invoice",
"total": "<string>",
"currency": "<string>",
"issued_date": "2023-12-25",
"sent_for_approval": true
},
"reported": {
"at": "2023-11-07T05:31:56Z",
"by": {
"user_id": "<string>",
"name": "<string>"
}
}
}
],
"truncated": true
}{
"error": {
"code": "validation_error",
"message": "The request is invalid. details lists up to 20 field errors. Request bodies are limited to 2 MiB.",
"request_id": "req_example"
}
}{
"error": {
"code": "invalid_token",
"message": "The bearer token is missing or invalid.",
"request_id": "req_example"
}
}{
"error": {
"code": "forbidden",
"message": "Access denied. The error code says why: forbidden, token_disabled, organization_required, insufficient_role or mfa_required.",
"request_id": "req_example"
}
}{
"error": {
"code": "rate_limit_exceeded",
"message": "Too many requests. Wait for the Retry-After delay before retrying.",
"request_id": "req_example"
}
}{
"error": {
"code": "internal_error",
"message": "Unexpected server failure. Include the request ID when contacting support.",
"request_id": "req_example"
}
}{
"error": {
"code": "service_unavailable",
"message": "Temporarily unavailable. Retry after the Retry-After delay, when provided.",
"request_id": "req_example"
}
}List what was received and needs attention
Lists what the organization received that did not become a checked invoice, newest first: Peppol, email and accounting-system imports that failed and will not retry themselves, received documents that are not invoices, invoices whose background runs did not finish after their retries, accounting connections that stopped bringing invoices in, Tripletex integrations whose sending stopped because the sign-in expired, and payment reminders for invoices not in Watchdog. Each member sees what concerns the imports and invoices they can see; connections only an admin can fix show to admins. Each kind shows its 100 newest items. An item leaves the list when it is resolved (the import retried or removed, a not_an_invoice file attached to an invoice, the invoice’s area run again, the connection renewed or signed in to again, the reminder linked) or marked as handled with markNeedsAttentionHandled; handled=true lists those. Members who turn it on in their notification settings also get a daily email of what is new here.
curl --request GET \
--url https://api.watchdog.no/v1/intake/needs-attention \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.watchdog.no/v1/intake/needs-attention', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.watchdog.no/v1/intake/needs-attention"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text){
"data": [
{
"kind": "import_failed",
"subject_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"occurred_at": "2023-11-07T05:31:56Z",
"handled": {
"at": "2023-11-07T05:31:56Z",
"by": {
"user_id": "<string>",
"name": "<string>"
}
},
"import_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"channel": "peppol",
"integration_name": "<string>",
"file_name": "<string>",
"document_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"reason": "<string>",
"failure_code": "<string>",
"cause": "not_an_invoice",
"owner": "organization",
"invoice": {
"supplier_name": "<string>",
"invoice_number": "<string>",
"total": "<string>",
"currency": "<string>",
"due_date": "2023-12-25"
},
"suggested_invoice": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"invoice_number": "<string>",
"supplier_name": "<string>",
"category": "invoice",
"total": "<string>",
"currency": "<string>",
"issued_date": "2023-12-25",
"sent_for_approval": true
},
"reported": {
"at": "2023-11-07T05:31:56Z",
"by": {
"user_id": "<string>",
"name": "<string>"
}
}
}
],
"truncated": true
}{
"error": {
"code": "validation_error",
"message": "The request is invalid. details lists up to 20 field errors. Request bodies are limited to 2 MiB.",
"request_id": "req_example"
}
}{
"error": {
"code": "invalid_token",
"message": "The bearer token is missing or invalid.",
"request_id": "req_example"
}
}{
"error": {
"code": "forbidden",
"message": "Access denied. The error code says why: forbidden, token_disabled, organization_required, insufficient_role or mfa_required.",
"request_id": "req_example"
}
}{
"error": {
"code": "rate_limit_exceeded",
"message": "Too many requests. Wait for the Retry-After delay before retrying.",
"request_id": "req_example"
}
}{
"error": {
"code": "internal_error",
"message": "Unexpected server failure. Include the request ID when contacting support.",
"request_id": "req_example"
}
}{
"error": {
"code": "service_unavailable",
"message": "Temporarily unavailable. Retry after the Retry-After delay, when provided.",
"request_id": "req_example"
}
}