> ## Documentation Index
> Fetch the complete documentation index at: https://astronomer.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Add a Deployment user role with the APC API

<Note>
  The examples on this page show common ways to use the APC API — they're not a complete API reference. For the full, interactive API documentation for your installation, including every available query, mutation, and type, go to `https://houston.<your-base-domain>/v1`, and click on the **Docs** tab. See [Develop and test APC API queries](/docs/astro-private-cloud/v-2-x/houston-api-develop-test) for more on using the built-in GraphQL explorer.
</Note>

Use the `deploymentAddUserRole` GraphQL mutation to add a user, or `deploymentUpdateUserRole` to change an existing user's role.

```graphql wrap theme={null}
mutation {
  deploymentAddUserRole(
    deploymentId: "<deployment-id>"
    email: "<user-email>"
    role: DEPLOYMENT_EDITOR
  ) {
    id
  }
}
```

Use `role: DEPLOYMENT_VIEWER` to restrict a user to read-only access instead.

For the full role-assignment flow, see [Manage users on Astro Private Cloud](/docs/astro-private-cloud/v-2-x/manage-platform-users).
