Last active
July 17, 2020 12:51
-
-
Save kaicode/35284eb322708875820d3dd90d33cbc4 to your computer and use it in GitHub Desktop.
Example API request to authenticate a user against the SNOMED International domain using the IMS API. If unsuccessful the response code is 404. If successful the response code is 200 and the Set-Cookie response header will contain the single sign-on authentication token.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ curl -i -XPOST -H 'Content-Type: application/json;charset=UTF-8' https://dev-ims.ihtsdotools.org/api/authenticate -d '{"login":"test-user", "password":"PutPasswordHere"}' | |
HTTP/1.1 200 | |
Server: nginx | |
Date: Fri, 17 Jul 2020 12:45:03 GMT | |
Content-Length: 0 | |
Connection: keep-alive | |
Set-Cookie: dev-ims-ihtsdo=CO1qkDHBRtjkCY9A6GjMnQAAAbbkskskACdGVzdC1hdXRobThingssdAA; Max-Age=259200; Expires=Mon, 20-Jul-2020 12:45:03 GMT; Domain=ihtsdotools.org; Path=/ | |
X-Content-Type-Options: nosniff | |
X-XSS-Protection: 1; mode=block | |
Cache-Control: no-cache, no-store, max-age=0, must-revalidate | |
Pragma: no-cache | |
Expires: 0 | |
X-Frame-Options: DENY | |
Strict-Transport-Security: max-age=15768000 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This example uses the IMS API within the online development environment.