...
HTTP Request with inquiry_created event |
Code Block |
---|
| # HTTP POST
# 'Content-Type': 'application/json'
# 'Accept': 'application/json'
{
"eventType": "inquiry_created",
"eventTime": "2020-12-09T16:09:53+00:00",
"eventId": "66948656-d8cd-452f-a9c5-000eca2d0684",
"eventNameTranslations": {
"de_DE": "Beratung erstellt"
},
"affected": [
{
"referenceType": "inquiry",
"referenceId": "567",
"links": [
{
"contentType": "application/json",
"href": "https://app.thinksurance.de/ipn/inquiry/567"
},
{
"contentType": "plain/html",
"href": "https://demopool.thinksurance.de/inquiry/32efda3424432"
}
]
},
{
"referenceType": "customer",
"referenceId": "789",
"links": [
{
"contentType": "application/xml",
"href": "https://app.thinksurance.de/ipn/customer/789"
}
]
},
{
"referenceType": "file",
"referenceId": "111",
"links": [
{
"contentType": "application/json",
"href": "https://app.thinksurance.de/api/v1/files/111"
},
{
"contentType": "application/pdf",
"href": "https://app.thinksurance.de/api/v1/files/111/download"
}
]
}
]
} |
|
HTTP Request with tender_cancelled event |
Code Block |
---|
| # HTTP POST
# 'Content-Type': 'application/json'
# 'Accept': 'application/json'
{
"eventType": "tender_cancelled",
"eventTime": "2020-12-09T16:09:53+00:00",
"eventId": "66948656-d8cd-452f-a9c5-000eca2d0684",
"eventNameTranslations": {
"de_DE": "Ausschreibung abgebrochen"
},
"affected": [
{
"referenceType": "tender",
"referenceId": "111"
},
{
"referenceType": "inquiry",
"referenceId": "567",
"links": [
{
"contentType": "application/json",
"href": "https://app.thinksurance.de/ipn/inquiry/567"
},
{
"contentType": "plain/html",
"href": "https://demopool.thinksurance.de/inquiry/32efda3424432"
}
]
}
]
} |
|
Successful HTTP Response |
Code Block |
---|
| # HTTP 204 status code |
|
Failed HTTP Response |
Code Block |
---|
| # HTTP 400 status code
# 'Content-Type': 'application/json'
{
"errors": [
"Unknown entity tender.",
"Attribute 'referenceId' is of the wrong type."
]
} |
|
...
Whenever some event occurs on the Thinksurance Platform, Notification System will notify Partner’s System via a webhook. After receiving a notification, the Partner’s system can get information about involved entities by sending HTTP requests to the API.
Drawio |
---|
mVer | 2 |
---|
zoom | 1 |
---|
simple | 0 |
---|
zoominComment | 10 |
---|
inCommentcustContentId | 03206479997 |
---|
pageId | 3207036929 |
---|
custContentIdlbox | 32064799971 |
---|
diagramDisplayName | Untitled Diagram-1708422561362.drawio | lbox |
---|
1 | contentVer | 1 |
---|
revision | 1 |
---|
baseUrl | https://thinksurance.atlassian.net/wiki |
---|
diagramName | Untitled Diagram-1708422561362.drawio |
---|
pCenter | 0 |
---|
width | 572 |
---|
links | |
---|
tbstyle | |
---|
height | 251 |
---|
|
Recommendation and expectation from Thinksurance side is that the Partner asynchronously fetch data about affected entities from the API, independent fro the original webhook HTTP request. That practically means that after a webhook, the partner is encouraged to store notification payload in some kind of internal storage and return 204 HTTP response.
After that, in a separate thread, the partner system should retrieve data bound to entities on the API.
Drawio |
---|
mVer | 2 |
---|
zoom | 1 |
---|
simple | 0 |
---|
zoominComment | 10 |
---|
inCommentcustContentId | 03206774994 |
---|
pageId | 3207036929 |
---|
custContentIdlbox | 32067749941 |
---|
diagramDisplayName | Untitled Diagram-1708422868420.drawio | lbox | 1 |
---|
contentVer | 1 |
---|
revision | 1 |
---|
baseUrl | https://thinksurance.atlassian.net/wiki |
---|
diagramName | Untitled Diagram-1708422868420.drawio |
---|
pCenter | 0 |
---|
width | 461 |
---|
links | |
---|
tbstyle | |
---|
height | 561 |
---|
|