Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Reverted from v. 2

...

To access the specific document, consumers must initiate an HTTP GET POST request to the /api/ipndoc/documentsget/{:documentIdtoken} endpoint. The documentId token parameter represents an unique identifier of the document in questionthe security token acquired during the Authentication process on the API. As essential components of the JSON payload within the body of the request, consumers are required to include the hash (serving as the document identifier) and bToken (functioning as the broker identifier).

Action name

get document

HTTP path

/api/ipndoc/documentsget/{:documentIdtoken}

  • documentId - an unique identifier of the requested document.token - a security token retrieved from Authentication

HTTP method

GETPOST

Attributes of the HTTP request

HTTP Request Header

hash

Authorization

X-Broker-Token

string

required

A security token provided from Authentication endpoint.
Required to provide as a Bearer Token (in format: “Bearer {{token}}“).

An unique identifier of the document.

bToken

string

required

An unique identifier of the broker.

Attributes of the HTTP response

...

This section shows examples of different HTTP requests and responses associated with the endpoint /api/ipndoc/documentsget/{:docuementIdtoken}.

HTTP Request without profession filter

json
Code Block
language
# HTTP GETPOST
# https://ipn.dev.thinksurance.de/api/ipn/documents/<some ID>
#
# HTTP headers
# 'Acceptapi/doc/get/{:token}
# 'Content-Type': 'application/json'
# 'Accept': 'application/json'
{
  "hash": "some encrypted string",
  "bToken": "some encrypted string"
}

HTTP Request with profession filter

Code Block
# HTTP POST
# /api//doc/get/{token}
# 'Content-Type': 'application/json'
# 'AuthorizationAccept': 'Bearer <someapplication/json'
{
  "token": "some long string value>'
# 'X-Broker-Token': '<some hash>'
# value",
  "professionId": 123
}

Successful HTTP Response

language
Code Block
json
# HTTP 200 status code
# 'Content-Type': 'text/pdf'
#
Base64 encoded payload

Failed HTTP Response

json
Code Block
language
# HTTP 200 status code
# 'Content-Type': 'application/json'
{
  "error": "API User is not existing or deactivated."
}