{"activeVersionTag":"latest","latestAvailableVersionTag":"latest","collection":{"info":{"_postman_id":"3ee5c2b4-81ea-4b7f-b452-9d27631d4e40","name":"Inserve API (online docs)","description":"<h3>Endpoint</h3>\n\n<p>De API is te bereiken op&nbsp;<code>https://[subdomein].inserve.nl/api/</code>. Alle responses zijn in het JSON formaat.</p>\n\n<h3>Authenticatie</h3>\n\n<p>Maak als ingelogde gebruiker een API-key aan via het profielmenu -&gt; API instellingen &gt; API sleutels. Gebruik deze bij elke request. Je kunt de authenticatie testen met het&nbsp;<code>/auth/me</code>&nbsp;endpoint, vervang hieronder&nbsp;<code>[apikey]</code>&nbsp;met een API sleutel:<br><br><b>GET</b>&nbsp;<code>https://[subdomein].inserve.nl/api/auth/me</code></p>\n\n<table><tbody><tr><th><br>Headers<br></th><td><div><code>X-Api-Key: [apikey]</code></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr><tr><th><br>Parameters<br></th><td><div><br>(leeg)<br></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr><tr><th><br>Response<br></th><td><div><code>{ \"id\": 1, \"email\": \"test@example.com\", \"...\": \"...\" }</code></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr></tbody></table>\n\n<h3>Voorbeeld</h3>\n\n<p>Gebruik de inspector in de browser om alle calls te bekijken. Alle calls in de front-end kunnen ook gebruikt worden met een API-key.</p>\n\n<h3>Tickets</h3>\n\n<p><b>GET</b><code>https://[subdomein].inserve.nl/api/tickets</code></p>\n\n<table><tbody><tr><th><br>Query (JSON-encoded)<br></th><td><div><br>(Zie querybuilder)<br><br><br><code>{ \"builder\": [ { \"orderByDesc\": \"created_at\" }, { \"paginate\": 15 } ], \"page\": 1 }</code></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr><tr><th><br>Response<br></th><td><div><code>{ \"current_page\": 1, \"data\": [ { \"id\": 9, \"reference\": \"ZYL7R\", \"description\": \"test\", \"client_id\": 9, \"operator_id\": 1, \"status_id\": 0, \"created_at\": \"2019-06-25T16:29:00+0200\", \"updated_at\": \"2019-06-27T13:35:02+0200\", \"priority\": 1, \"ticket_time_registrations_sum\": null, \"operator\": { \"id\": 1, \"email\": \"admin@innovaat.nl\", \"email_verified_at\": null, \"first_name\": \"abc\", \"last_name\": \"abc\", \"telephone_cell\": null, \"telephone\": null, \"companies\": [], \"remember_token\": null, \"created_at\": \"2019-06-07T17:19:56+0200\", \"updated_at\": \"2019-06-07T17:19:56+0200\", \"deleted_at\": null, \"roles_ids\": [ 1 ], \"roles\": [ { \"id\": 1, \"name\": \"operator\", \"display_name\": \"Behandelaar\", \"description\": null, \"created_at\": \"2019-06-07 13:56:48\", \"updated_at\": \"2019-06-07 13:56:48\", \"pivot\": { \"user_id\": 1, \"role_id\": 1 } } ] }, \"client\": { \"id\": 9, \"email\": \"hans@hanos.nl\", \"email_verified_at\": null, \"first_name\": \"Hans\", \"last_name\": null, \"telephone_cell\": \"06-2348912304\", \"telephone\": \"0487-623489\", \"company_id\": 1, \"remember_token\": null, \"created_at\": \"2019-06-25T16:28:56+0200\", \"updated_at\": \"2019-06-25T17:05:46+0200\", \"deleted_at\": null, \"roles_ids\": [ 2 ], \"company\": { \"id\": 1, \"name\": \"Xenos BV\", \"debtor_code\": null, \"address_1\": \"Weg\", \"address_2\": \"2\", \"postal_code\": \"5881 AM\", \"telephone\": \"0412\", \"logo\": null, \"city\": \"Boxmeer\", \"country\": \"Nederland\", \"created_at\": \"2019-06-20T16:53:46+0200\", \"updated_at\": \"2019-06-25T14:34:14+0200\" }, \"roles\": [ { \"id\": 2, \"name\": \"client\", \"display_name\": \"Contactpersoon\", \"description\": null, \"created_at\": \"2019-06-07 13:56:48\", \"updated_at\": \"2019-06-07 13:56:48\", \"pivot\": { \"user_id\": 9, \"role_id\": 2 } } ] } } ], \"first_page_url\": \"http://test.myapp.com/tickets?page=1\", \"from\": 1, \"last_page\": 1, \"last_page_url\": \"http://test.myapp.com/tickets?page=1\", \"next_page_url\": null, \"path\": \"http://test.myapp.com/tickets\", \"per_page\": \"15\", \"prev_page_url\": null, \"to\": 1, \"total\": 1 }</code></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr></tbody></table>\n\n<h3>Query builder</h3>\n\n<p>De API gebruikt de<a href=\"https://laravel.com/docs/master/queries\">Query Builder</a>van Laravel om objecten op te halen. Hier een aantal voorbeelden:</p>\n\n<table><tbody><tr><th><br>Query filtering<br></th><td><div><code>{\"builder\":[{\"where\":[\"status_id\",4]},{\"where\":[\"created_at\",\"&gt;\",\"2019-06-30 15:00:00\"]},{\"whereIn\":[\"status_id\",[2,3,4]]},{\"s\":\"John Doe\"}]}</code></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr><tr><th><br>Query ordering<br></th><td><div><code>{\"builder\":[{\"orderBy\":\"created_at\"},{\"orderByDesc\":\"created_at\"}]}</code></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr><tr><th><br>Query relations<br></th><td><div><code>{\"builder\":[{\"with\":[\"client\",\"client.company\"]},{\"withCount\":\"ticketMessages\"}]}</code></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr><tr><th><br>Modifiers (leave empty for all results)<br></th><td><div><code>{\"builder\":[{\"count\":[\"\\\\\\\\\\\\\\\\\\\\*\"]},{\"paginate\":15}]}</code></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr><tr><th><br>&nbsp;<br></th><td><div><br>&nbsp;<br></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr><tr><th><br>Example 1<br></th><td><div><code>{\"builder\":[{\"whereIn\":[\"status_id\",[2,3,4]]},{\"paginate\":15}]}</code></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr><tr><th><br>&nbsp;<br></th><td><div><br>&nbsp;<br></div><div contenteditable=\"false\"><div><div><div></div></div></div><div></div></div></td></tr></tbody></table>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","isPublicCollection":false,"owner":"14835414","team":1633182,"collectionId":"3ee5c2b4-81ea-4b7f-b452-9d27631d4e40","publishedId":"2s935kQ6UW","public":true,"publicUrl":"https://documenter-api.postman.tech/view/14835414/2s935kQ6UW","privateUrl":"https://go.postman.co/documentation/14835414-3ee5c2b4-81ea-4b7f-b452-9d27631d4e40","customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"documentationLayout":"classic-double-column","customisation":{"metaTags":[{"name":"description","value":""},{"name":"title","value":""}],"appearance":{"default":"system_default","themes":[{"name":"dark","logo":null,"colors":{"top-bar":"212121","right-sidebar":"303030","highlight":"FF6C37"}},{"name":"light","logo":null,"colors":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"}}]}},"version":"8.10.1","publishDate":"2025-04-17T13:10:20.000Z","activeVersionTag":"latest","documentationTheme":"light","metaTags":{"title":"","description":""},"logos":{"logoLight":null,"logoDark":null}},"statusCode":200},"environments":[],"user":{"authenticated":false,"permissions":{"publish":false}},"run":{"button":{"js":"https://run.pstmn.io/button.js","css":"https://run.pstmn.io/button.css"}},"web":"https://www.getpostman.com/","team":{"logo":"https://res.cloudinary.com/postman/image/upload/t_team_logo_pubdoc/v1/team/3d68e90c8ec80b14af281fe82e86f1d57b944badca4239472b3f3207a007e4d4","favicon":""},"isEnvFetchError":false,"languages":"[{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"HttpClient\"},{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"RestSharp\"},{\"key\":\"curl\",\"label\":\"cURL\",\"variant\":\"cURL\"},{\"key\":\"dart\",\"label\":\"Dart\",\"variant\":\"http\"},{\"key\":\"go\",\"label\":\"Go\",\"variant\":\"Native\"},{\"key\":\"http\",\"label\":\"HTTP\",\"variant\":\"HTTP\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"OkHttp\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"Unirest\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"Fetch\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"jQuery\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"XHR\"},{\"key\":\"c\",\"label\":\"C\",\"variant\":\"libcurl\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Axios\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Native\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Request\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Unirest\"},{\"key\":\"objective-c\",\"label\":\"Objective-C\",\"variant\":\"NSURLSession\"},{\"key\":\"ocaml\",\"label\":\"OCaml\",\"variant\":\"Cohttp\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"cURL\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"Guzzle\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"HTTP_Request2\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"pecl_http\"},{\"key\":\"powershell\",\"label\":\"PowerShell\",\"variant\":\"RestMethod\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"http.client\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"Requests\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"httr\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"RCurl\"},{\"key\":\"ruby\",\"label\":\"Ruby\",\"variant\":\"Net::HTTP\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"Httpie\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"wget\"},{\"key\":\"swift\",\"label\":\"Swift\",\"variant\":\"URLSession\"}]","languageSettings":[{"key":"csharp","label":"C#","variant":"HttpClient"},{"key":"csharp","label":"C#","variant":"RestSharp"},{"key":"curl","label":"cURL","variant":"cURL"},{"key":"dart","label":"Dart","variant":"http"},{"key":"go","label":"Go","variant":"Native"},{"key":"http","label":"HTTP","variant":"HTTP"},{"key":"java","label":"Java","variant":"OkHttp"},{"key":"java","label":"Java","variant":"Unirest"},{"key":"javascript","label":"JavaScript","variant":"Fetch"},{"key":"javascript","label":"JavaScript","variant":"jQuery"},{"key":"javascript","label":"JavaScript","variant":"XHR"},{"key":"c","label":"C","variant":"libcurl"},{"key":"nodejs","label":"NodeJs","variant":"Axios"},{"key":"nodejs","label":"NodeJs","variant":"Native"},{"key":"nodejs","label":"NodeJs","variant":"Request"},{"key":"nodejs","label":"NodeJs","variant":"Unirest"},{"key":"objective-c","label":"Objective-C","variant":"NSURLSession"},{"key":"ocaml","label":"OCaml","variant":"Cohttp"},{"key":"php","label":"PHP","variant":"cURL"},{"key":"php","label":"PHP","variant":"Guzzle"},{"key":"php","label":"PHP","variant":"HTTP_Request2"},{"key":"php","label":"PHP","variant":"pecl_http"},{"key":"powershell","label":"PowerShell","variant":"RestMethod"},{"key":"python","label":"Python","variant":"http.client"},{"key":"python","label":"Python","variant":"Requests"},{"key":"r","label":"R","variant":"httr"},{"key":"r","label":"R","variant":"RCurl"},{"key":"ruby","label":"Ruby","variant":"Net::HTTP"},{"key":"shell","label":"Shell","variant":"Httpie"},{"key":"shell","label":"Shell","variant":"wget"},{"key":"swift","label":"Swift","variant":"URLSession"}],"languageOptions":[{"label":"C# - HttpClient","value":"csharp - HttpClient - C#"},{"label":"C# - RestSharp","value":"csharp - RestSharp - C#"},{"label":"cURL - cURL","value":"curl - cURL - cURL"},{"label":"Dart - http","value":"dart - http - Dart"},{"label":"Go - Native","value":"go - Native - Go"},{"label":"HTTP - HTTP","value":"http - HTTP - HTTP"},{"label":"Java - OkHttp","value":"java - OkHttp - Java"},{"label":"Java - Unirest","value":"java - Unirest - Java"},{"label":"JavaScript - Fetch","value":"javascript - Fetch - JavaScript"},{"label":"JavaScript - jQuery","value":"javascript - jQuery - JavaScript"},{"label":"JavaScript - XHR","value":"javascript - XHR - JavaScript"},{"label":"C - libcurl","value":"c - libcurl - C"},{"label":"NodeJs - Axios","value":"nodejs - Axios - NodeJs"},{"label":"NodeJs - Native","value":"nodejs - Native - NodeJs"},{"label":"NodeJs - Request","value":"nodejs - Request - NodeJs"},{"label":"NodeJs - Unirest","value":"nodejs - Unirest - NodeJs"},{"label":"Objective-C - NSURLSession","value":"objective-c - NSURLSession - Objective-C"},{"label":"OCaml - Cohttp","value":"ocaml - Cohttp - OCaml"},{"label":"PHP - cURL","value":"php - cURL - PHP"},{"label":"PHP - Guzzle","value":"php - Guzzle - PHP"},{"label":"PHP - HTTP_Request2","value":"php - HTTP_Request2 - PHP"},{"label":"PHP - pecl_http","value":"php - pecl_http - PHP"},{"label":"PowerShell - RestMethod","value":"powershell - RestMethod - PowerShell"},{"label":"Python - http.client","value":"python - http.client - Python"},{"label":"Python - Requests","value":"python - Requests - Python"},{"label":"R - httr","value":"r - httr - R"},{"label":"R - RCurl","value":"r - RCurl - R"},{"label":"Ruby - Net::HTTP","value":"ruby - Net::HTTP - Ruby"},{"label":"Shell - Httpie","value":"shell - Httpie - Shell"},{"label":"Shell - wget","value":"shell - wget - Shell"},{"label":"Swift - URLSession","value":"swift - URLSession - Swift"}],"layoutOptions":[{"value":"classic-single-column","label":"Single Column"},{"value":"classic-double-column","label":"Double Column"}],"versionOptions":[],"environmentOptions":[{"value":"0","label":"No Environment"}],"canonicalUrl":"https://documenter.gw.postman.com/view/metadata/2s935kQ6UW"}