diff --git a/openapi.json b/openapi.json index c04d3c1..c9c618e 100644 --- a/openapi.json +++ b/openapi.json @@ -8414,7 +8414,7 @@ }, "summary": "Create a New Department", "operationId": "Create a New Department", - "description": "You may create a Department using this action. It takes a JSON object containing a Department.", + "description": "You may create a Department using this action. It takes a JSON object containing a Department.\n\nAuthorization depends on the type of API key you use:\n\n| Account-wide key | Department-specific key |\n| --- | --- |\n| Allowed | Not permitted |", "tags": [ "Departments" ], @@ -8580,7 +8580,7 @@ }, "summary": "View a Department", "operationId": "View a Department", - "description": "", + "description": "View a single Department.\n\nAuthorization depends on the type of API key you use:\n\n| Account-wide key | Department-specific key |\n| --- | --- |\n| Any Department in the account | Its own Department only |", "tags": [ "Departments" ], @@ -8675,7 +8675,7 @@ }, "summary": "Update a Department", "operationId": "Update a Department", - "description": "", + "description": "Update a Department using this action. It takes a JSON object containing a Department.\n\nAuthorization depends on the type of API key you use:\n\n| Account-wide key | Department-specific key |\n| --- | --- |\n| Any Department in the account | Its own Department only |", "tags": [ "Departments" ], @@ -8834,7 +8834,7 @@ }, "summary": "Delete a Department", "operationId": "Delete a Department", - "description": "", + "description": "Delete a Department using this action.\n\nAuthorization depends on the type of API key you use:\n\n| Account-wide key | Department-specific key |\n| --- | --- |\n| Allowed | Not permitted |", "tags": [ "Departments" ], @@ -8942,7 +8942,7 @@ }, "summary": "Search for Departments", "operationId": "Search for Departments", - "description": "You can search for departments by various search criteria.", + "description": "You can search for departments by various search criteria.\n\nAuthorization depends on the type of API key you use:\n\n| Account-wide key | Department-specific key |\n| --- | --- |\n| All Departments in the account | Its own Department only |", "tags": [ "Departments" ], @@ -9581,7 +9581,7 @@ "items": { "type": "object", "properties": { - "department_id": { + "department": { "type": "number" }, "permissions": { @@ -9613,6 +9613,30 @@ "items": { "type": "number" } + }, + "api": { + "type": "boolean" + }, + "team": { + "type": "boolean" + }, + "spotlight_directory": { + "type": "boolean" + }, + "access_level": { + "type": "string", + "enum": [ + "organization_admin", + "department_admin", + "team_member", + "developer" + ] + }, + "analytics_email": { + "type": "boolean" + }, + "manage_dept_admins_and_devs": { + "type": "boolean" } }, "required": [ @@ -9626,7 +9650,7 @@ } }, "required": [ - "department_id", + "department", "permissions" ] } @@ -9642,7 +9666,7 @@ "email": "person@example.com", "department_permissions": [ { - "department_id": 34, + "department": 34, "permissions": { "designs": true, "emails": true, @@ -9651,11 +9675,17 @@ "settings": true, "role": "editor", "pathways": true, - "groups": [1, 2, 3] + "groups": [1, 2, 3], + "api": false, + "team": true, + "spotlight_directory": false, + "access_level": "department_admin", + "analytics_email": true, + "manage_dept_admins_and_devs": true } }, { - "department_id": 35, + "department": 35, "permissions": { "designs": false, "emails": false, @@ -9664,7 +9694,13 @@ "settings": false, "role": "viewer", "pathways": false, - "groups": null + "groups": null, + "api": false, + "team": false, + "spotlight_directory": false, + "access_level": "team_member", + "analytics_email": false, + "manage_dept_admins_and_devs": false } } ] @@ -9676,7 +9712,7 @@ }, "summary": "Create a Team Member", "operationId": "Create a Team Member", - "description": "Create a TeamMember using this action. It requires a JSON object containing an TeamMember.", + "description": "Create a TeamMember using this action. It requires a JSON object containing a TeamMember.\n\n**Important**\n\n- Organization Admin cannot be created through the API.\n- To create a Department Admin or Developer your account must be on the Connect/Growth Plan.\n\nThe `access_level` of each `department_permissions` entry determines what is created, and authorization is based on the type of API key you use:\n\n| Access Level | Account-wide key | Department-specific key |\n| --- | --- | --- |\n| Team Member (default) | Any Department in the account | Its own Department only |\n| Department Admin | Any Department in the account | Not permitted |\n| Developer | Any Department in the account | Not permitted |\n| Organization Admin | Not permitted | Not permitted |\n\n**Permitted values by `access_level`.**\n\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
FieldTeam MemberDepartment Admin*Developer*
access_levelteam_memberdepartment_admindeveloper
roleeditor
credential_issuer
viewer
editorviewer
apiNAfalsetruetrue
designstrue
false
true
false
trueNA
emailstrue
false
true
false
trueNA
credential_attributestrue
false
true
false
trueNA
analyticstrue
false
true
false
trueNA
settingstrue
false
true
false
trueNA
pathwaystrue
false
true
false
trueNA
teamNAtrue
false
trueNA
analytics_emailNAtrue
false
trueNA
manage_dept_admins_and_devsNAtrue
false
trueNA
groupsArray of Group IDs to limit access toNA (All groups allowed)NA (All groups allowed)
\n\n*NA - Not Applicable, can be omitted.*
* *Only available on Connect/Growth Plan.*", "tags": [ "Team Members" ], @@ -9698,7 +9734,12 @@ "settings": true, "role": "editor", "pathways": true, - "groups": [1, 2, 3] + "groups": [1, 2, 3], + "api": false, + "team": true, + "access_level": "department_admin", + "analytics_email": true, + "manage_dept_admins_and_devs": true } }, { @@ -9711,7 +9752,12 @@ "settings": false, "role": "viewer", "pathways": false, - "groups": null + "groups": null, + "api": false, + "team": false, + "access_level": "team_member", + "analytics_email": false, + "manage_dept_admins_and_devs": false } } ] @@ -9763,13 +9809,43 @@ }, "role": { "type": "string", - "description": "\"editor\" or \"viewer\" access to Credential data in the Department." + "description": "\"editor\", \"credential_issuer\" or \"viewer\" access to Credential data in the Department." }, "pathways": { "type": "boolean", "default": false, "description": "Should the TeamMember have access to Pathways for the given Department?" }, + "api": { + "type": "boolean", + "default": false, + "description": "Should the TeamMember have access to API keys for the given Department?" + }, + "team": { + "type": "boolean", + "default": false, + "description": "Should the TeamMember be able to manage other Team Members in the given Department?" + }, + "access_level": { + "type": "string", + "enum": [ + "team_member", + "department_admin", + "developer" + ], + "default": "team_member", + "description": "The TeamMember's access level in the given Department." + }, + "analytics_email": { + "type": "boolean", + "default": false, + "description": "Should the TeamMember receive scheduled Analytics emails for the given Department?" + }, + "manage_dept_admins_and_devs": { + "type": "boolean", + "default": false, + "description": "Should the TeamMember be able to manage Department Admins and Developers in the given Department?" + }, "groups": { "type": "array", "description": "Limit the TeamMember access to specific Groups in the Department.", @@ -9813,7 +9889,7 @@ { "lang": "cURL", "label": "cURL", - "source": "curl -X POST \\\n \"https://api.accredible.com/v1/team_members\" \\\n -H \"Authorization: Token token=YOUR_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"team_member\": {\n \"name\": \"John Doe\",\n \"email\": \"person@example.com\",\n \"department_permissions\": [\n {\n \"department_id\": 34,\n \"permissions\": {\n \"designs\": true,\n \"emails\": true,\n \"credential_attributes\": true,\n \"analytics\": true,\n \"settings\": true,\n \"role\": \"editor\",\n \"pathways\": true,\n \"groups\": [1, 2, 3]\n }\n },\n {\n \"department_id\": 35,\n \"permissions\": {\n \"designs\": false,\n \"emails\": false,\n \"credential_attributes\": false,\n \"analytics\": false,\n \"settings\": false,\n \"role\": \"viewer\",\n \"pathways\": false,\n \"groups\": null\n }\n }\n ]\n }\n}'" + "source": "curl -X POST \\\n \"https://api.accredible.com/v1/team_members\" \\\n -H \"Authorization: Token token=YOUR_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"team_member\": {\n \"name\": \"John Doe\",\n \"email\": \"person@example.com\",\n \"department_permissions\": [\n {\n \"department_id\": 34,\n \"permissions\": {\n \"designs\": true,\n \"emails\": true,\n \"credential_attributes\": true,\n \"analytics\": true,\n \"settings\": true,\n \"role\": \"editor\",\n \"pathways\": true,\n \"groups\": [1, 2, 3],\n \"api\": false,\n \"team\": true,\n \"access_level\": \"department_admin\",\n \"analytics_email\": true,\n \"manage_dept_admins_and_devs\": true\n }\n },\n {\n \"department_id\": 35,\n \"permissions\": {\n \"designs\": false,\n \"emails\": false,\n \"credential_attributes\": false,\n \"analytics\": false,\n \"settings\": false,\n \"role\": \"viewer\",\n \"pathways\": false,\n \"groups\": null,\n \"api\": false,\n \"team\": false,\n \"access_level\": \"team_member\",\n \"analytics_email\": false,\n \"manage_dept_admins_and_devs\": false\n }\n }\n ]\n }\n}'" } ] } @@ -9846,7 +9922,7 @@ "items": { "type": "object", "properties": { - "department_id": { + "department": { "type": "number" }, "permissions": { @@ -9879,12 +9955,36 @@ "type": "number" }, "nullable": true + }, + "api": { + "type": "boolean" + }, + "team": { + "type": "boolean" + }, + "spotlight_directory": { + "type": "boolean" + }, + "access_level": { + "type": "string", + "enum": [ + "organization_admin", + "department_admin", + "team_member", + "developer" + ] + }, + "analytics_email": { + "type": "boolean" + }, + "manage_dept_admins_and_devs": { + "type": "boolean" } } } }, "required": [ - "department_id", + "department", "permissions" ] } @@ -9900,7 +10000,7 @@ "email": "person@example.com", "department_permissions": [ { - "department_id": 34, + "department": 34, "permissions": { "designs": true, "emails": true, @@ -9913,11 +10013,17 @@ 1, 2, 3 - ] + ], + "api": false, + "team": true, + "spotlight_directory": false, + "access_level": "department_admin", + "analytics_email": true, + "manage_dept_admins_and_devs": true } }, { - "department_id": 35, + "department": 35, "permissions": { "designs": false, "emails": false, @@ -9926,7 +10032,13 @@ "settings": false, "role": "viewer", "pathways": false, - "groups": null + "groups": null, + "api": false, + "team": false, + "spotlight_directory": false, + "access_level": "team_member", + "analytics_email": false, + "manage_dept_admins_and_devs": false } } ] @@ -9938,7 +10050,7 @@ }, "summary": "View a Team Member", "operationId": "View a Team Member", - "description": "", + "description": "View a TeamMember and their permissions in each Department.\n\nWhich TeamMembers you can view depends on the type of API key you use:\n\n| Access Level | Account-wide key | Department-specific key |\n| --- | --- | --- |\n| Team Member | Any Department in the account | Its own Department only |\n| Department Admin | Any Department in the account | Its own Department only |\n| Developer | Any Department in the account | Its own Department only |\n| Organization Admin | Visible | Not visible |", "tags": [ "Team Members" ], @@ -9982,7 +10094,7 @@ "items": { "type": "object", "properties": { - "department_id": { + "department": { "type": "number" }, "permissions": { @@ -10015,12 +10127,36 @@ "type": "number" }, "nullable": true + }, + "api": { + "type": "boolean" + }, + "team": { + "type": "boolean" + }, + "spotlight_directory": { + "type": "boolean" + }, + "access_level": { + "type": "string", + "enum": [ + "organization_admin", + "department_admin", + "team_member", + "developer" + ] + }, + "analytics_email": { + "type": "boolean" + }, + "manage_dept_admins_and_devs": { + "type": "boolean" } } } }, "required": [ - "department_id", + "department", "permissions" ] } @@ -10036,7 +10172,7 @@ "email": "person@example.com", "department_permissions": [ { - "department_id": 34, + "department": 34, "permissions": { "designs": false, "emails": false, @@ -10049,11 +10185,17 @@ 1, 2, 3 - ] + ], + "api": false, + "team": true, + "spotlight_directory": false, + "access_level": "department_admin", + "analytics_email": true, + "manage_dept_admins_and_devs": true } }, { - "department_id": 35, + "department": 35, "permissions": { "designs": false, "emails": false, @@ -10062,7 +10204,13 @@ "settings": false, "role": "viewer", "pathways": false, - "groups": null + "groups": null, + "api": false, + "team": false, + "spotlight_directory": false, + "access_level": "team_member", + "analytics_email": false, + "manage_dept_admins_and_devs": false } } ] @@ -10074,7 +10222,7 @@ }, "summary": "Update a Team Member", "operationId": "Update a Team Member", - "description": "Update a TeamMember using this action. It requires a JSON object containing an TeamMember.", + "description": "Update a TeamMember using this action. It requires a JSON object containing a TeamMember.\n\n**Important**\n\n- Organization Admin cannot be created or updated through the API.\n- To assign a Department Admin or Developer your account must be on the Connect/Growth Plan.\n\n**The `department_permissions` array replaces the TeamMember's entire permission set.** A Department present in the array is created or updated; a Department omitted from the array has its permission removed, if your API key is authorized to remove it.\n\nWhich TeamMembers you can update depends on the type of API key you use:\n\n| Access Level | Account-wide key | Department-specific key |\n| --- | --- | --- |\n| Team Member | Any Department in the account | Its own Department only |\n| Department Admin | Any Department in the account | Not permitted |\n| Developer | Any Department in the account | Not permitted |\n| Organization Admin | Not permitted | Not permitted |\n\n**Permitted values by `access_level`.**\n\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
FieldTeam MemberDepartment Admin*Developer*
access_levelteam_memberdepartment_admindeveloper
roleeditor
credential_issuer
viewer
editorviewer
apiNAfalsetruetrue
designstrue
false
true
false
trueNA
emailstrue
false
true
false
trueNA
credential_attributestrue
false
true
false
trueNA
analyticstrue
false
true
false
trueNA
settingstrue
false
true
false
trueNA
pathwaystrue
false
true
false
trueNA
teamNAtrue
false
trueNA
analytics_emailNAtrue
false
trueNA
manage_dept_admins_and_devsNAtrue
false
trueNA
groupsArray of Group IDs to limit access toNA (All groups allowed)NA (All groups allowed)
\n\n*NA - Not Applicable, can be omitted.*
* *Only available on Connect/Growth Plan.*", "tags": [ "Team Members" ], @@ -10098,7 +10246,12 @@ 1, 2, 3 - ] + ], + "api": false, + "team": true, + "access_level": "department_admin", + "analytics_email": true, + "manage_dept_admins_and_devs": true } }, { @@ -10111,7 +10264,12 @@ "settings": false, "role": "viewer", "pathways": false, - "groups": null + "groups": null, + "api": false, + "team": false, + "access_level": "team_member", + "analytics_email": false, + "manage_dept_admins_and_devs": false } } ] @@ -10126,11 +10284,7 @@ }, "name": { "type": "string", - "description": "The name of the TeamMember user." - }, - "email": { - "type": "string", - "description": "The email address of the TeamMember user." + "description": "The name of the TeamMember user. A blank value leaves the existing name unchanged." }, "department_permissions": { "type": "array", @@ -10166,13 +10320,43 @@ }, "role": { "type": "string", - "description": "\"editor\" or \"viewer\" access to Credential data in the Department." + "description": "\"editor\", \"credential_issuer\" or \"viewer\" access to Credential data in the Department." }, "pathways": { "type": "boolean", "default": false, "description": "Should the TeamMember have access to Pathways for the given Department?" }, + "api": { + "type": "boolean", + "default": false, + "description": "Should the TeamMember have access to API keys for the given Department?" + }, + "team": { + "type": "boolean", + "default": false, + "description": "Should the TeamMember be able to manage other Team Members in the given Department?" + }, + "access_level": { + "type": "string", + "enum": [ + "team_member", + "department_admin", + "developer" + ], + "default": "team_member", + "description": "The TeamMember's access level in the given Department." + }, + "analytics_email": { + "type": "boolean", + "default": false, + "description": "Should the TeamMember receive scheduled Analytics emails for the given Department?" + }, + "manage_dept_admins_and_devs": { + "type": "boolean", + "default": false, + "description": "Should the TeamMember be able to manage Department Admins and Developers in the given Department?" + }, "groups": { "description": "Limit the TeamMember access to specific Groups in the Department." } @@ -10192,7 +10376,7 @@ "permissions" ] }, - "description": "This parameter will override any existing permissions, not append to them." + "description": "This parameter replaces the TeamMember's entire set of permissions, it does not append to them." } }, "required": [ @@ -10211,7 +10395,7 @@ { "lang": "cURL", "label": "cURL", - "source": "curl -X PUT \\\n \"https://api.accredible.com/v1/team_members/12345\" \\\n -H \"Authorization: Token token=YOUR_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"team_member\": {\n \"department_permissions\": [\n {\n \"department_id\": 34,\n \"permissions\": {\n \"designs\": false,\n \"emails\": false,\n \"credential_attributes\": true,\n \"analytics\": true,\n \"settings\": true,\n \"role\": \"editor\",\n \"pathways\": true,\n \"groups\": [\n 1,\n 2,\n 3\n ]\n }\n },\n {\n \"department_id\": 35,\n \"permissions\": {\n \"designs\": false,\n \"emails\": false,\n \"credential_attributes\": false,\n \"analytics\": false,\n \"settings\": false,\n \"role\": \"viewer\",\n \"pathways\": false,\n \"groups\": null\n }\n }\n ]\n }\n}'" + "source": "curl -X PUT \\\n \"https://api.accredible.com/v1/team_members/12345\" \\\n -H \"Authorization: Token token=YOUR_API_KEY\" \\\n -H \"Content-Type: application/json\" \\\n -d '{\n \"team_member\": {\n \"department_permissions\": [\n {\n \"department_id\": 34,\n \"permissions\": {\n \"designs\": false,\n \"emails\": false,\n \"credential_attributes\": true,\n \"analytics\": true,\n \"settings\": true,\n \"role\": \"editor\",\n \"pathways\": true,\n \"groups\": [\n 1,\n 2,\n 3\n ],\n \"api\": false,\n \"team\": true,\n \"access_level\": \"department_admin\",\n \"analytics_email\": true,\n \"manage_dept_admins_and_devs\": true\n }\n },\n {\n \"department_id\": 35,\n \"permissions\": {\n \"designs\": false,\n \"emails\": false,\n \"credential_attributes\": false,\n \"analytics\": false,\n \"settings\": false,\n \"role\": \"viewer\",\n \"pathways\": false,\n \"groups\": null,\n \"api\": false,\n \"team\": false,\n \"access_level\": \"team_member\",\n \"analytics_email\": false,\n \"manage_dept_admins_and_devs\": false\n }\n }\n ]\n }\n}'" } ] }, @@ -10242,7 +10426,7 @@ "items": { "type": "object", "properties": { - "department_id": { + "department": { "type": "number" }, "permissions": { @@ -10275,12 +10459,36 @@ "type": "number" }, "nullable": true + }, + "api": { + "type": "boolean" + }, + "team": { + "type": "boolean" + }, + "spotlight_directory": { + "type": "boolean" + }, + "access_level": { + "type": "string", + "enum": [ + "organization_admin", + "department_admin", + "team_member", + "developer" + ] + }, + "analytics_email": { + "type": "boolean" + }, + "manage_dept_admins_and_devs": { + "type": "boolean" } } } }, "required": [ - "department_id", + "department", "permissions" ] } @@ -10296,7 +10504,7 @@ "email": "person@example.com", "department_permissions": [ { - "department_id": 34, + "department": 34, "permissions": { "designs": true, "emails": true, @@ -10309,11 +10517,17 @@ 1, 2, 3 - ] + ], + "api": false, + "team": true, + "spotlight_directory": false, + "access_level": "department_admin", + "analytics_email": true, + "manage_dept_admins_and_devs": true } }, { - "department_id": 35, + "department": 35, "permissions": { "designs": false, "emails": false, @@ -10322,7 +10536,13 @@ "settings": false, "role": "viewer", "pathways": false, - "groups": null + "groups": null, + "api": false, + "team": false, + "spotlight_directory": false, + "access_level": "team_member", + "analytics_email": false, + "manage_dept_admins_and_devs": false } } ] @@ -10334,7 +10554,7 @@ }, "summary": "Delete a Team Member", "operationId": "Delete a Team Member", - "description": "", + "description": "Remove a TeamMember from the Departments your API key can reach.\n\nWhat the request removes depends on the type of API key you use:\n\n| Access Level | Account-wide key | Department-specific key |\n| --- | --- | --- |\n| Team Member | Any Department in the account | Its own Department only |\n| Department Admin | Any Department in the account | Not removed |\n| Developer | Any Department in the account | Not removed |\n| Organization Admin | Not removed | Not removed |", "tags": [ "Team Members" ],