Content Management API > SSO User
Delete a SSO user
Query parameters
destination_user_type enum
New owner for resources previously owned by the deleted SSO user. This argument specifies the new owner type.
Example:
"user"
account
user
access_token
sso_user
destination_user_id string
New owner for resources previously owned by the deleted SSO user. This argument specifies the new owner ID.
Example:
"7865"
Returns
Returns a resource object of type sso_user
Examples
import { buildClient } from "@datocms/cma-client-node";
async function run() { const client = buildClient({ apiToken: process.env.DATOCMS_API_TOKEN });
const userId = "312";
const ssoUser = await client.ssoUsers.destroy(userId);
// Check the 'Returned output' tab for the result ☝️ console.log(ssoUser);}
run();
{ id: "312", username: "mark.smith@example.com", external_id: "Ja23ekjhsad", is_active: true, first_name: "Mark", last_name: "Smith", meta: { last_access: "2018-03-25T21:50:24.914Z" }, groups: [{ type: "sso_group", id: "312" }], role: { type: "role", id: "34" },}