Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Attributes of the HTTP request

token

HTTP Request Header

Authorization

string

required

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

JSON Body

professionId

int

optional

An attribute used to filter out all products for particular profession.

...

HTTP Request without profession filter

Code Block
# HTTP POST
# https://ipn.dev.thinksurance.de/api/ipn/products
#
# HTTP headers
# 'Content-Type': 'application/json'
# 'Accept': 'application/json'
{# 'Authorization':  "token": "some'Bearer <some long string value>'
value"# }

HTTP Request with profession filter

Code Block
# HTTP POST
# https://ipn.dev.thinksurance.de/api/ipn/products
#
# HTTP headers
# 'Content-Type': 'application/json'
# 'Accept': 'application/json'
{# 'Authorization':  "token": "some 'Bearer <some long string value", value>'
#
{
  "professionId": 123
}

Successful HTTP Response

Code Block
# HTTP 200 status code
# 'Content-Type': 'application/json'
[
  {
    "id": 1,
    "name": "Product1"
  },
  {
    "id": 2,
    "name": "Product2"
  }
]

Failed HTTP Response

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