Secret Manager API
Stores sensitive data such as API keys, passwords, and certificates. Provides convenience while improving security.
Identity & security#openapi#analytics#media
Fork copies the collection into your workspace, without the publisher's secrets, so you can add your own key and send requests. Star saves it to your starred APIs (Account › Marketplace) and helps others find it.
Overview
Stores sensitive data such as API keys, passwords, and certificates. Provides convenience while improving security.
Endpoints 17
projects.secrets.versions
- GETGets metadata for a SecretVersion
/v1/:nameGets metadata for a SecretVersion. projects/*/secrets/*/versions/latest is an alias to the most recently created SecretVersion. - GETAccesses a SecretVersion
/v1/:name:accessAccesses a SecretVersion. This call returns the secret data. projects/*/secrets/*/versions/latest is an alias to the most recently created SecretVersion. - POSTDestroys a SecretVersion
/v1/:name:destroyDestroys a SecretVersion. Sets the state of the SecretVersion to DESTROYED and irrevocably destroys the secret data. - POSTDisables a SecretVersion
/v1/:name:disableDisables a SecretVersion. Sets the state of the SecretVersion to DISABLED. - POSTEnables a SecretVersion
/v1/:name:enableEnables a SecretVersion. Sets the state of the SecretVersion to ENABLED. - GETLists SecretVersions
/v1/:parent/versions?filter=string&pageSize=0&pageToken=stringLists SecretVersions. This call does not return secret data.
projects.secrets
- DELETEDeletes a Secret.
/v1/:name?etag=stringDeletes a Secret. - PATCHUpdates metadata of an existing Secret.
/v1/:name?updateMask=stringUpdates metadata of an existing Secret. - POSTCreates a new SecretVersion containing secret data and attaches it to an existing Secret.
/v1/:parent:addVersionCreates a new SecretVersion containing secret data and attaches it to an existing Secret. - GETLists Secrets.
/v1/:parent/secrets?filter=string&pageSize=0&pageToken=stringLists Secrets. - POSTCreates a new Secret containing no SecretVersions.
/v1/:parent/secrets?secretId=stringCreates a new Secret containing no SecretVersions. - POSTEnables the managed rotation feature for a Secret
/v1/:parent:enableManagedRotationEnables the managed rotation feature for a Secret. This method can only be triggered once for a secret. In order to do further rotations, RotateSecret should… - GETGets the access control policy for a secret
/v1/:resource:getIamPolicy?options.requestedPolicyVersion=0Gets the access control policy for a secret. Returns empty policy if the secret exists and does not have a policy set. - POSTDo a managed rotation for a Secret
/v1/:parent:rotateSecretDo a managed rotation for a Secret. This can only be triggered after Managed rotation has been enabled. This method will add a secret version and update the… - POSTSets the access control policy on the specified secret
/v1/:resource:setIamPolicySets the access control policy on the specified secret. Replaces any existing policy. Permissions on SecretVersions are enforced according to the policy set… - POSTReturns permissions that a caller has for the specified secret
/v1/:resource:testIamPermissionsReturns permissions that a caller has for the specified secret. If the secret does not exist, this call returns an empty set of permissions, not a NOT_FOUND…
projects.locations
- GETLists information about the supported locations for this service
/v1/:name/locations?extraLocationTypes=string&filter=string&pageSize=0&pageToken=stringLists information about the supported locations for this service. This method lists locations based on the resource scope provided in the…
API details
- Base URL
https://secretmanager.googleapis.com- Authentication
- OAuth 2.0 (authorization code flow) with 1 scope
An API key in the key query parameter - Operations
- 17 operations on 14 pathsPOST 9GET 6PATCH 1DELETE 1
- Main resources
- projects.secrets 10projects.secrets.versions 6projects.locations 1
- Response formats
application/json- Description format
- Google API Discovery, API version
v1 - Links
- Documentation · OpenAPI document
- Listed from
- Google API Discovery document (googleapis/discovery-artifact-manager) (Apache-2.0)
How to test the Secret Manager API in Swastik Codes
- Open the APISelect “Fork & run in Swastik Codes” on this page. Sign in or create a free account if asked.
- Fork it into your workspaceChoose a workspace. You get your own copy of the Secret Manager API collection, without the publisher's secrets.
- Add your credentialsThis API uses OAuth 2.0 (authorization code flow) with 1 scope. Add yours in the collection's variables or an environment; the requests already reference it.
- Send a requestPick an endpoint, for example “Gets metadata for a SecretVersion” (GET /v1/:name), and press Send. Check the response, add tests and run the whole collection with the runner.
Frequently asked questions
What is the Secret Manager API?
Stores sensitive data such as API keys, passwords, and certificates. Provides convenience while improving security. It is listed under Identity & security and has 17 endpoints.
Who publishes the Secret Manager API?
It is listed from Google's public API description (an OpenAPI document), not published by Google on Swastik Codes. Anyone who controls googleapis.com can claim the profile by adding a DNS TXT record.
What is the base URL of the Secret Manager API?
Requests go to https://secretmanager.googleapis.com. Endpoint paths are added to this base URL.
How do I authenticate with the Secret Manager API?
It accepts 2 methods: OAuth 2.0 (authorization code flow) with 1 scope; an API key in the key query parameter.
How many endpoints does the Secret Manager API have?
17 operations on 14 paths (9 POST, 6 GET, 1 PATCH, 1 DELETE). The largest groups are projects.secrets, projects.secrets.versions, projects.locations.
Is forking the Secret Manager API free?
Yes. Forking copies the collection into your workspace for free. It has been starred 0 times and forked 0 times.