Last active
June 12, 2020 11:04
-
-
Save thomaspoignant/b4177130fe961f30e8bc20b328066d62 to your computer and use it in GitHub Desktop.
A scenario to test your SCIM integration
This file contains hidden or 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
| { | |
| "trigger_url": "https://api.runscope.com/radar/e9283ad0-af77-45b4-81ee-0e59bd5ff932/trigger", | |
| "name": "SCIM 2.0 SPEC Test", | |
| "version": "1.0", | |
| "steps": [ | |
| { | |
| "url": "{{SCIMBaseURL}}/Users?count=1&startIndex=1", | |
| "variables": [ | |
| { | |
| "source": "response_json", | |
| "property": "Resources[0].id", | |
| "name": "ISVUserid" | |
| } | |
| ], | |
| "step_type": "request", | |
| "headers": { | |
| "Accept-Charset": [ | |
| "utf-8" | |
| ], | |
| "Content-Type": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ], | |
| "Accept": [ | |
| "application/scim+json" | |
| ], | |
| "User-Agent": [ | |
| "SCIM Integration" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "200", | |
| "source": "response_status" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "Resources", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "has_value", | |
| "property": "schemas", | |
| "value": "urn:ietf:params:scim:api:messages:2.0:ListResponse", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_a_number", | |
| "property": "itemsPerPage", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_a_number", | |
| "property": "startIndex", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_a_number", | |
| "property": "totalResults", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "Resources[0].id", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "Resources[0].name.familyName", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "Resources[0].name.givenName", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "Resources[0].userName", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "Resources[0].active", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "Resources[0].emails[0].value", | |
| "value": null, | |
| "source": "response_json" | |
| } | |
| ], | |
| "method": "GET" | |
| }, | |
| { | |
| "duration": 5, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "url": "{{SCIMBaseURL}}/Users/{{ISVUserid}}", | |
| "variables": [], | |
| "step_type": "request", | |
| "headers": { | |
| "Accept-Charset": [ | |
| "utf-8" | |
| ], | |
| "Content-Type": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ], | |
| "Accept": [ | |
| "application/scim+json" | |
| ], | |
| "User-Agent": [ | |
| "SCIM Integration" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "200", | |
| "source": "response_status" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "id", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "name.familyName", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "name.givenName", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "userName", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "active", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "emails[0].value", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "id", | |
| "value": "{{ISVUserid}}", | |
| "source": "response_json" | |
| } | |
| ], | |
| "method": "GET" | |
| }, | |
| { | |
| "duration": 5, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "url": "{{SCIMBaseURL}}/Users?filter=userName eq \"{{InvalidUserEmail}}\"", | |
| "variables": [], | |
| "step_type": "request", | |
| "headers": { | |
| "Accept-Charset": [ | |
| "utf-8" | |
| ], | |
| "Content-Type": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ], | |
| "Accept": [ | |
| "application/scim+json" | |
| ], | |
| "User-Agent": [ | |
| "SCIM Integration" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "200", | |
| "source": "response_status" | |
| }, | |
| { | |
| "comparison": "has_value", | |
| "property": "schemas", | |
| "value": "urn:ietf:params:scim:api:messages:2.0:ListResponse", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "totalResults", | |
| "value": "0", | |
| "source": "response_json" | |
| } | |
| ], | |
| "method": "GET" | |
| }, | |
| { | |
| "duration": 5, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "url": "{{SCIMBaseURL}}/Users/{{UserIdThatDoesNotExist}}", | |
| "variables": [], | |
| "step_type": "request", | |
| "headers": { | |
| "Accept-Charset": [ | |
| "utf-8" | |
| ], | |
| "Content-Type": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Accept": [ | |
| "application/scim+json" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ], | |
| "User-Agent": [ | |
| "SCIM Integration" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "404", | |
| "source": "response_status" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "detail", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "has_value", | |
| "property": "schemas", | |
| "value": "urn:ietf:params:scim:api:messages:2.0:Error", | |
| "source": "response_json" | |
| } | |
| ], | |
| "method": "GET" | |
| }, | |
| { | |
| "duration": 5, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "url": "{{SCIMBaseURL}}/Users?filter=userName eq \"{{randomEmail}}\"", | |
| "variables": [], | |
| "step_type": "request", | |
| "headers": { | |
| "Accept-Charset": [ | |
| "utf-8" | |
| ], | |
| "Content-Type": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Accept": [ | |
| "application/scim+json" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ], | |
| "User-Agent": [ | |
| "SCIM Integration" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "200", | |
| "source": "response_status" | |
| }, | |
| { | |
| "comparison": "equal_number", | |
| "property": "totalResults", | |
| "value": "0", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "has_value", | |
| "property": "schemas", | |
| "value": "urn:ietf:params:scim:api:messages:2.0:ListResponse", | |
| "source": "response_json" | |
| } | |
| ], | |
| "method": "GET" | |
| }, | |
| { | |
| "duration": 5, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "body": "{\"schemas\":[\"urn:ietf:params:scim:schemas:core:2.0:User\"],\"userName\":\"{{randomUsername}}\",\"name\":{\"givenName\":\"{{randomGivenName}}\",\"familyName\":\"{{randomFamilyName}}\"},\"emails\":[{\"primary\":true,\"value\":\"{{randomEmail}}\",\"type\":\"work\"}],\"displayName\":\"{{randomGivenName}} {{randomFamilyName}}\",\"active\":true}", | |
| "url": "{{SCIMBaseURL}}/Users", | |
| "variables": [ | |
| { | |
| "source": "response_json", | |
| "property": "id", | |
| "name": "idUserOne" | |
| }, | |
| { | |
| "source": "response_json", | |
| "property": "emails[0].value", | |
| "name": "randomUserEmail" | |
| } | |
| ], | |
| "step_type": "request", | |
| "headers": { | |
| "Content-Type": [ | |
| "application/json" | |
| ], | |
| "Accept": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "201", | |
| "source": "response_status" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "active", | |
| "value": "true", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "id", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "name.familyName", | |
| "value": "{{randomFamilyName}}", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "name.givenName", | |
| "value": "{{randomGivenName}}", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "contains", | |
| "property": "schemas", | |
| "value": "urn:ietf:params:scim:schemas:core:2.0:User", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "userName", | |
| "value": "{{randomUsername}}", | |
| "source": "response_json" | |
| } | |
| ], | |
| "method": "POST" | |
| }, | |
| { | |
| "duration": 5, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "url": "{{SCIMBaseURL}}/Users/{{idUserOne}}", | |
| "variables": [], | |
| "step_type": "request", | |
| "headers": { | |
| "Accept-Charset": [ | |
| "utf-8" | |
| ], | |
| "Content-Type": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Accept": [ | |
| "application/scim+json" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ], | |
| "User-Agent": [ | |
| "SCIM Integration" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "200", | |
| "source": "response_status" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "userName", | |
| "value": "{{randomUsername}}", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "name.familyName", | |
| "value": "{{randomFamilyName}}", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "name.givenName", | |
| "value": "{{randomGivenName}}", | |
| "source": "response_json" | |
| } | |
| ], | |
| "method": "GET" | |
| }, | |
| { | |
| "duration": 5, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "url": "{{SCIMBaseURL}}/Users/{{idUserOne}}", | |
| "body": "{\"schemas\":[\"urn:ietf:params:scim:schemas:core:2.0:User\"],\"userName\":\"{{randomUsername}}\",\"name\":{\"givenName\":\"{{randomGivenName}}\",\"familyName\":\"{{randomFamilyName}}\"},\"emails\":[{\"primary\":true,\"value\":\"{{randomEmail}}\",\"type\":\"work\"}],\"displayName\":\"{{randomGivenName}} {{randomFamilyName}}\",\"active\":false}", | |
| "variables": [], | |
| "step_type": "request", | |
| "headers": { | |
| "Accept-Charset": [ | |
| "utf-8" | |
| ], | |
| "Content-Type": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Accept": [ | |
| "application/scim+json" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ], | |
| "User-Agent": [ | |
| "SCIM Integration" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "200", | |
| "source": "response_status" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "active", | |
| "value": "false", | |
| "source": "response_json" | |
| } | |
| ], | |
| "method": "PUT" | |
| }, | |
| { | |
| "duration": 5, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "url": "{{SCIMBaseURL}}/Users/{{idUserOne}}", | |
| "body": "{\"schemas\": [\"urn:ietf:params:scim:api:messages:2.0:PatchOp\"],\"Operations\": [{\"op\": \"replace\", \"path\": \"active\", \"value\": true}]}", | |
| "variables": [], | |
| "step_type": "request", | |
| "headers": { | |
| "Accept-Charset": [ | |
| "utf-8" | |
| ], | |
| "Content-Type": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Accept": [ | |
| "application/scim+json" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ], | |
| "User-Agent": [ | |
| "SCIM Integration" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "200", | |
| "source": "response_status" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "active", | |
| "value": "true", | |
| "source": "response_json" | |
| } | |
| ], | |
| "method": "PATCH" | |
| }, | |
| { | |
| "duration": 10, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "body": "{\"schemas\":[\"urn:ietf:params:scim:schemas:core:2.0:User\"],\"userName\":\"{{randomUsername}}\",\"name\":{\"givenName\":\"{{randomGivenName}}\",\"familyName\":\"{{randomFamilyName}}\"},\"emails\":[{\"primary\":true,\"value\":\"{{randomUsername}}\",\"type\":\"work\"}],\"displayName\":\"{{randomGivenName}} {{randomFamilyName}}\",\"active\":true}", | |
| "url": "{{SCIMBaseURL}}/Users", | |
| "variables": [], | |
| "step_type": "request", | |
| "headers": { | |
| "Content-Type": [ | |
| "application/json" | |
| ], | |
| "Accept": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "409", | |
| "source": "response_status" | |
| } | |
| ], | |
| "method": "POST" | |
| }, | |
| { | |
| "duration": 5, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "url": "{{SCIMBaseURL}}/Users?filter=userName eq \"{{randomUsernameCaps}}\"", | |
| "variables": [], | |
| "step_type": "request", | |
| "headers": { | |
| "Accept-Charset": [ | |
| "utf-8" | |
| ], | |
| "Content-Type": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Accept": [ | |
| "application/scim+json" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ], | |
| "User-Agent": [ | |
| "SCIM Integration" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal_number", | |
| "value": "200", | |
| "source": "response_status" | |
| } | |
| ], | |
| "method": "GET" | |
| }, | |
| { | |
| "duration": 5, | |
| "step_type": "pause" | |
| }, | |
| { | |
| "url": "{{SCIMBaseURL}}/Groups", | |
| "variables": [], | |
| "step_type": "request", | |
| "headers": { | |
| "Accept-Charset": [ | |
| "utf-8" | |
| ], | |
| "Content-Type": [ | |
| "application/scim+json; charset=utf-8" | |
| ], | |
| "Authorization": [ | |
| "{{auth}}" | |
| ], | |
| "Accept": [ | |
| "application/scim+json" | |
| ], | |
| "User-Agent": [ | |
| "SCIM Integration" | |
| ] | |
| }, | |
| "assertions": [ | |
| { | |
| "comparison": "equal", | |
| "property": "fs", | |
| "value": "200", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_equal", | |
| "property": "", | |
| "value": "600", | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "empty", | |
| "property": "emails", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "not_empty", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "contains", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "does_not_contain", | |
| "property": "dddd", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_a_number", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_a_number", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_a_number", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_a_number", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "equal", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_a_number", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_a_number", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_a_number", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "has_key", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "has_value", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| }, | |
| { | |
| "comparison": "is_null", | |
| "property": "", | |
| "value": null, | |
| "source": "response_json" | |
| } | |
| ], | |
| "method": "GET" | |
| } | |
| ] | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment