Integrations
Clerk
Connect Clerk to Alter Vault for secure API access
Overview
Section titled “Overview”Use Clerk credentials to make authenticated API calls through Alter Vault without exposing API keys in code.
| Property | Value |
|---|---|
| Template ID | clerk |
| Category | Developer Tools |
| Credential Type | Bearer Token |
Step 1: Get Credentials
Section titled “Step 1: Get Credentials”Log in to the Clerk Dashboard
Log in to the Clerk Dashboard and select the application.
Open API keys
In the left sidebar, open API keys.
Copy the Secret Key
Under Secret keys, copy the Secret Key (starts with sk_live_ or sk_test_).
Step 2: Add to Alter Vault
Section titled “Step 2: Add to Alter Vault”Open the Developer Portal
Go to portal.alterauth.com and navigate to the application.
Add Clerk
Go to Managed Secrets > Add Provider > Clerk.
Enter credentials
Paste the Secret Key into the credential field.
Save
Click Save. You’ll receive a grant_id to use with the SDK.
Using in Code
Section titled “Using in Code”from alter_sdk import PendingApprovalresponse = await alter_app.proxy_request( HttpMethod.GET, "https://api.clerk.com/v1/users", grant_id="YOUR_GRANT_ID",)if isinstance(response, PendingApproval): for gate in response.gates: print("Approval required:", gate.approval_url) response = await alter_app.await_approval(response.approval_id)Policy-cataloged operations
Section titled “Policy-cataloged operations”Alter policy rules can target these attested operations and families for operation-level and parameter-aware controls.
| Operation ID | Families | Method | Provider path | Notes |
|---|---|---|---|---|
GetUserList | read | GET | /v1/users | — |
CreateUser | write | POST | /v1/users | — |
GetUsersCount | read | GET | /v1/users/count | — |
GetUser | read | GET | /v1/users/{user_id} | — |
UpdateUser | write | PATCH | /v1/users/{user_id} | — |
DeleteUser | delete | DELETE | /v1/users/{user_id} | — |
UpdateUserMetadata | write | PATCH | /v1/users/{user_id}/metadata | — |
BanUser | admin | POST | /v1/users/{user_id}/ban | — |
UnbanUser | admin | POST | /v1/users/{user_id}/unban | — |
GetOAuthAccessToken | read | GET | /v1/users/{user_id}/oauth_access_tokens/{provider} | refused by default: hands the caller a provider credential, or revokes the connection’s own (a credential_minting rule can allow it) |
UsersGetOrganizationMemberships | read | GET | /v1/users/{user_id}/organization_memberships | — |
CreateInvitation | admin, send, write | POST | /v1/invitations | allowed; its secret is never stored in a payload capture |
ListInvitations | read | GET | /v1/invitations | allowed; its secret is never stored in a payload capture |
RevokeInvitation | admin | POST | /v1/invitations/{invitation_id}/revoke | — |
ListOrganizations | read | GET | /v1/organizations | — |
CreateOrganization | write | POST | /v1/organizations | — |
GetOrganization | read | GET | /v1/organizations/{organization_id} | — |
UpdateOrganization | admin, write | PATCH | /v1/organizations/{organization_id} | — |
DeleteOrganization | delete | DELETE | /v1/organizations/{organization_id} | — |
ListOrganizationMemberships | read | GET | /v1/organizations/{organization_id}/memberships | — |
CreateOrganizationMembership | admin, send, write | POST | /v1/organizations/{organization_id}/memberships | — |
GetSessionList | read | GET | /v1/sessions | — |
GetSession | read | GET | /v1/sessions/{session_id} | — |
RevokeSession | admin, delete | POST | /v1/sessions/{session_id}/revoke | — |
CreateSessionToken | admin | POST | /v1/sessions/{session_id}/tokens | refused by default: hands the caller a provider credential, or revokes the connection’s own (a credential_minting rule can allow it) |
GetJWKS | read | GET | /v1/jwks | — |
CreateSignInToken | admin | POST | /v1/sign_in_tokens | refused by default: hands the caller a provider credential, or revokes the connection’s own (a credential_minting rule can allow it); served by the provider but absent from its published spec |
CreateActorToken | admin | POST | /v1/actor_tokens | refused by default: hands the caller a provider credential, or revokes the connection’s own (a credential_minting rule can allow it); served by the provider but absent from its published spec |