{"openapi":"3.1.0","info":{"title":"CloudBurrow Metadata and Credentials","version":"v0.3.0","description":"Use the local metadata server with Google clients that look for an instance identity. This reference covers v0.3.0. Point GCE_METADATA_HOST at the running instance’s metadata address. The tokens and signatures exercise local client flows and grant no access to Google services. The IAM Credentials methods check permissions on service accounts created through the IAM API. They do not check calls that name the instance’s own account."},"servers":[{"url":"http://127.0.0.1:9005","description":"Default local metadata listener"}],"externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"tags":[{"name":"Compute metadata"},{"name":"Local token exchange"},{"name":"IAM Credentials fixture"},{"name":"Service account certificates"}],"paths":{"/":{"get":{"tags":["Compute metadata"],"operationId":"probeMetadata","summary":"Probe the metadata server","description":"Clients can check the response header to detect a local metadata server.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"parameters":[{"name":"Metadata-Flavor","in":"header","required":true,"description":"Required on compute metadata requests.","schema":{"type":"string","const":"Google"},"example":"Google"}],"responses":{"200":{"description":"Plain-text metadata value.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"computeMetadata/\n"}}},"403":{"description":"The Metadata-Flavor request header is missing or incorrect.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"Metadata-Flavor: Google header is required\n"}}}}}},"/computeMetadata/v1/project/project-id":{"get":{"tags":["Compute metadata"],"operationId":"getMetadataProject","summary":"Get the instance project ID","description":"Returns the project ID configured for this instance.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"parameters":[{"name":"Metadata-Flavor","in":"header","required":true,"description":"Required on compute metadata requests.","schema":{"type":"string","const":"Google"},"example":"Google"}],"responses":{"200":{"description":"Plain-text metadata value.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"cloudburrow"}}},"403":{"description":"The Metadata-Flavor request header is missing or incorrect.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"Metadata-Flavor: Google header is required\n"}}}}}},"/computeMetadata/v1/instance/zone":{"get":{"tags":["Compute metadata"],"operationId":"getMetadataZone","summary":"Get the local zone","description":"Returns a fully qualified zone with the local project number.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"parameters":[{"name":"Metadata-Flavor","in":"header","required":true,"description":"Required on compute metadata requests.","schema":{"type":"string","const":"Google"},"example":"Google"}],"responses":{"200":{"description":"Plain-text metadata value.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"projects/819629726105/zones/us-central1-a"}}},"403":{"description":"The Metadata-Flavor request header is missing or incorrect.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"Metadata-Flavor: Google header is required\n"}}}}}},"/computeMetadata/v1/instance/service-accounts/":{"get":{"tags":["Compute metadata"],"operationId":"listMetadataAccounts","summary":"List metadata service accounts","description":"Returns the default alias and the service account email. Requests addressed through a Cloud Run workload’s metadata hostname see that workload’s configured account.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"parameters":[{"name":"Metadata-Flavor","in":"header","required":true,"description":"Required on compute metadata requests.","schema":{"type":"string","const":"Google"},"example":"Google"}],"responses":{"200":{"description":"Plain-text metadata value.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"default/\ncloudburrow-local@cloudburrow.iam.gserviceaccount.com/\n"}}},"403":{"description":"The Metadata-Flavor request header is missing or incorrect.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"Metadata-Flavor: Google header is required\n"}}}}}},"/computeMetadata/v1/instance/service-accounts/{account}/email":{"get":{"tags":["Compute metadata"],"operationId":"getMetadataAccountEmail","summary":"Get the service account email","description":"Returns the email represented by the account.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"parameters":[{"name":"Metadata-Flavor","in":"header","required":true,"description":"Required on compute metadata requests.","schema":{"type":"string","const":"Google"},"example":"Google"},{"name":"account","in":"path","required":true,"description":"The alias default or the email listed for the current instance or workload.","schema":{"type":"string"},"example":"default"}],"responses":{"200":{"description":"Plain-text metadata value.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"cloudburrow-local@cloudburrow.iam.gserviceaccount.com"}}},"403":{"description":"The Metadata-Flavor request header is missing or incorrect.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"Metadata-Flavor: Google header is required\n"}}},"404":{"description":"The supplied account is neither default nor the account email.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"service account not found\n"}}}}}},"/computeMetadata/v1/instance/service-accounts/{account}/aliases":{"get":{"tags":["Compute metadata"],"operationId":"getMetadataAccountAliases","summary":"Get the service account aliases","description":"Returns the default alias.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"parameters":[{"name":"Metadata-Flavor","in":"header","required":true,"description":"Required on compute metadata requests.","schema":{"type":"string","const":"Google"},"example":"Google"},{"name":"account","in":"path","required":true,"description":"The alias default or the email listed for the current instance or workload.","schema":{"type":"string"},"example":"default"}],"responses":{"200":{"description":"Plain-text metadata value.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"default"}}},"403":{"description":"The Metadata-Flavor request header is missing or incorrect.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"Metadata-Flavor: Google header is required\n"}}},"404":{"description":"The supplied account is neither default nor the account email.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"service account not found\n"}}}}}},"/computeMetadata/v1/instance/service-accounts/{account}/scopes":{"get":{"tags":["Compute metadata"],"operationId":"getMetadataAccountScopes","summary":"Get the service account scopes","description":"Returns the scope advertised by the local fixture.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"parameters":[{"name":"Metadata-Flavor","in":"header","required":true,"description":"Required on compute metadata requests.","schema":{"type":"string","const":"Google"},"example":"Google"},{"name":"account","in":"path","required":true,"description":"The alias default or the email listed for the current instance or workload.","schema":{"type":"string"},"example":"default"}],"responses":{"200":{"description":"Plain-text metadata value.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"https://www.googleapis.com/auth/cloud-platform\n"}}},"403":{"description":"The Metadata-Flavor request header is missing or incorrect.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"Metadata-Flavor: Google header is required\n"}}},"404":{"description":"The supplied account is neither default nor the account email.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"service account not found\n"}}}}}},"/computeMetadata/v1/instance/service-accounts/{account}/token":{"get":{"tags":["Compute metadata"],"operationId":"getMetadataAccessToken","summary":"Get a local access token","description":"Issues an opaque fixture access token. The example is a placeholder.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"parameters":[{"name":"Metadata-Flavor","in":"header","required":true,"description":"Required on compute metadata requests.","schema":{"type":"string","const":"Google"},"example":"Google"},{"name":"account","in":"path","required":true,"description":"The alias default or the email listed for the current instance or workload.","schema":{"type":"string"},"example":"default"}],"responses":{"200":{"description":"Local OAuth-style token response.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccessToken"},"example":{"access_token":"cbl_example_local_token","expires_in":3600,"token_type":"Bearer"}}}},"403":{"description":"The Metadata-Flavor request header is missing or incorrect.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"Metadata-Flavor: Google header is required\n"}}},"404":{"description":"The supplied account is neither default nor the account email.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"service account not found\n"}}}}}},"/computeMetadata/v1/instance/service-accounts/{account}/identity":{"get":{"tags":["Compute metadata"],"operationId":"getMetadataIdentityToken","summary":"Get a local identity token","description":"Issues an RS256 JWT for the requested audience, signed by this instance’s key. Use the local JWKS to verify it. The example is a placeholder.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"parameters":[{"name":"Metadata-Flavor","in":"header","required":true,"description":"Required on compute metadata requests.","schema":{"type":"string","const":"Google"},"example":"Google"},{"name":"account","in":"path","required":true,"description":"The alias default or the email listed for the current instance or workload.","schema":{"type":"string"},"example":"default"},{"name":"audience","in":"query","required":true,"description":"Intended audience to put in the JWT.","schema":{"type":"string","minLength":1},"example":"https://example.invalid/local-service"}],"responses":{"200":{"description":"JWT as plain text.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"example-header.example-payload.example-signature"}}},"400":{"description":"A non-empty audience is required.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"non-empty audience parameter required\n"}}},"403":{"description":"The Metadata-Flavor request header is missing or incorrect.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"Metadata-Flavor: Google header is required\n"}}},"404":{"description":"The supplied account is neither default nor the account email.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"service account not found\n"}}},"500":{"description":"The local signer could not produce a token.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"}}}}}}},"/token":{"post":{"tags":["Local token exchange"],"operationId":"exchangeLocalToken","summary":"Exchange a local credential","description":"The generated credentials fixture and IAM service account key files use this OAuth-style endpoint. Send a non-empty assertion or refresh token. An assertion signed with an IAM service account key must verify against an enabled key of a live account, and must name that account. Other values return a local token.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-credentials-fixture"},"requestBody":{"required":true,"description":"Use the generated credentials fixture with your client. This assertion is a synthetic placeholder.","content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/TokenExchange"},"example":{"grant_type":"urn:ietf:params:oauth:grant-type:jwt-bearer","assertion":"example-local-assertion"}}}},"responses":{"200":{"description":"Local OAuth-style token response.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccessToken"},"example":{"access_token":"cbl_example_local_token","expires_in":3600,"token_type":"Bearer"}}}},"400":{"description":"The form could not be parsed or did not include a credential, or a service account key assertion was refused with invalid_grant.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"},"example":"{\"error\":\"invalid_request\",\"error_description\":\"missing assertion\"}\n"}}}}}},"/certs":{"get":{"tags":["Local token exchange"],"operationId":"getLocalSigningKeys","summary":"Get local signing keys","description":"Returns the public JSON Web Key Set for this instance’s signer. Read the instance’s actual response to verify locally issued JWTs.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#the-metadata-server"},"responses":{"200":{"description":"JWKS containing the local RSA public signing key. The sample key material is illustrative.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"keys":{"type":"array","items":{"$ref":"#/components/schemas/PublicSigningKey"}}},"required":["keys"]},"example":{"keys":[{"kty":"RSA","alg":"RS256","use":"sig","kid":"example-key-id","n":"example-modulus","e":"AQAB"}]}}}},"500":{"description":"The server could not encode the public key.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"text/plain":{"schema":{"type":"string"}}}}}}},"/v1/projects/-/serviceAccounts/{account}:generateAccessToken":{"post":{"tags":["IAM Credentials fixture"],"operationId":"generateLocalAccessToken","summary":"Generate an impersonated access token","description":"Returns an opaque local access token for the account. When the account is a service account created through the IAM API, the request needs a bearer token this instance minted, and its principal needs the permission Google requires on the account. The instance’s own account (`-` or the credentials fixture’s email) is not checked. For an IAM service account, scope is required and lifetime can be at most 3600 seconds. For the instance’s own account, lifetime defaults to 3600 seconds and can be up to 43200 seconds.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#service-account-impersonation-iam-credentials"},"parameters":[{"name":"account","in":"path","required":true,"description":"Service account email to use in this local test.","schema":{"type":"string"},"example":"test-runner@example-project.iam.gserviceaccount.com"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"scope":{"type":"array","items":{"type":"string"}},"lifetime":{"type":"string","default":"3600s"}}},"example":{"scope":["https://www.googleapis.com/auth/cloud-platform"],"lifetime":"3600s"}}}},"responses":{"200":{"description":"Access token and UTC expiration time.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"accessToken":{"type":"string"},"expireTime":{"type":"string","format":"date-time"}},"required":["accessToken","expireTime"]},"example":{"accessToken":"cbl_example_local_token","expireTime":"2026-01-01T13:00:00Z"}}}},"400":{"description":"The JSON body is malformed or an operation field is invalid.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"401":{"description":"An IAM service account was named and the request has no bearer token this instance minted.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"403":{"description":"The caller lacks roles/iam.serviceAccountTokenCreator, or an equivalent permission, on the named IAM service account or its project, or the account does not exist.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}}}}},"/v1/projects/-/serviceAccounts/{account}:generateIdToken":{"post":{"tags":["IAM Credentials fixture"],"operationId":"generateLocalIdToken","summary":"Generate an impersonated ID token","description":"Signs an RS256 JWT for the supplied audience with this instance’s key. Set includeEmail to include the impersonated account’s email claim. When the account is a service account created through the IAM API, the request needs a bearer token this instance minted, and its principal needs the permission Google requires on the account. The instance’s own account (`-` or the credentials fixture’s email) is not checked.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#service-account-impersonation-iam-credentials"},"parameters":[{"name":"account","in":"path","required":true,"description":"Service account email to use in this local test.","schema":{"type":"string"},"example":"test-runner@example-project.iam.gserviceaccount.com"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"audience":{"type":"string","minLength":1},"includeEmail":{"type":"boolean","default":false}},"required":["audience"]},"example":{"audience":"https://example.invalid/local-service","includeEmail":true}}}},"responses":{"200":{"description":"Locally signed ID token. The example is a placeholder.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"token":{"type":"string"}},"required":["token"]},"example":{"token":"example-header.example-payload.example-signature"}}}},"400":{"description":"The JSON body is malformed or an operation field is invalid.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"401":{"description":"An IAM service account was named and the request has no bearer token this instance minted.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"403":{"description":"The caller lacks roles/iam.serviceAccountTokenCreator, or an equivalent permission, on the named IAM service account or its project, or the account does not exist.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"500":{"description":"The local signer could not sign the token.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}}}}},"/v1/projects/-/serviceAccounts/{account}:signBlob":{"post":{"tags":["IAM Credentials fixture"],"operationId":"signLocalBlob","summary":"Sign bytes locally","description":"Signs base64-encoded bytes with RSASSA-PKCS1-v1_5 and SHA-256, using the IAM service account’s system-managed key. When the account is a service account created through the IAM API, the request needs a bearer token this instance minted, and its principal needs the permission Google requires on the account. The instance’s own account (`-` or the credentials fixture’s email) is not checked. A signed URL made with this signature is not accepted by Google services. The instance’s own account returns 501 UNIMPLEMENTED.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#service-account-impersonation-iam-credentials"},"parameters":[{"name":"account","in":"path","required":true,"description":"Service account email to use in this local test.","schema":{"type":"string"},"example":"test-runner@example-project.iam.gserviceaccount.com"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"payload":{"type":"string","format":"byte","minLength":1},"delegates":{"type":"array","items":{"type":"string"}}},"required":["payload"]},"example":{"payload":"aGVsbG8="}}}},"responses":{"200":{"description":"Key ID and base64 signature. The example is a placeholder.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"keyId":{"type":"string"},"signedBlob":{"type":"string","format":"byte"}},"required":["keyId","signedBlob"]},"example":{"keyId":"example-key-id","signedBlob":"ZXhhbXBsZS1zaWduYXR1cmU="}}}},"400":{"description":"The JSON body is malformed, the payload is missing, or the account is disabled.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"401":{"description":"An IAM service account was named and the request has no bearer token this instance minted.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"403":{"description":"The caller lacks roles/iam.serviceAccountTokenCreator, or an equivalent permission, on the named IAM service account or its project, or the account does not exist.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"500":{"description":"The local signer could not sign the bytes.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"501":{"description":"The account is the instance’s own account, which has no key for signBlob.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}}}}},"/v1/projects/-/serviceAccounts/{account}:signJwt":{"post":{"tags":["IAM Credentials fixture"],"operationId":"signLocalJwt","summary":"Sign JWT claims locally","description":"Signs a JSON object of claims. Pass the JSON object as a string in payload. When the account is a service account created through the IAM API, the request needs a bearer token this instance minted, and its principal needs the permission Google requires on the account. The instance’s own account (`-` or the credentials fixture’s email) is not checked. An IAM service account signs with its system-managed key, and an exp claim more than 12 hours ahead is refused. The instance’s own account signs with this instance’s key.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/docs/credentials.md#service-account-impersonation-iam-credentials"},"parameters":[{"name":"account","in":"path","required":true,"description":"Service account email to use in this local test.","schema":{"type":"string"},"example":"test-runner@example-project.iam.gserviceaccount.com"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"payload":{"type":"string","minLength":1}},"required":["payload"]},"example":{"payload":"{\"aud\":\"https://example.invalid/local-service\"}"}}}},"responses":{"200":{"description":"Key ID and locally signed JWT. The example is a placeholder.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"keyId":{"type":"string"},"signedJwt":{"type":"string"}},"required":["keyId","signedJwt"]},"example":{"keyId":"example-key-id","signedJwt":"example-header.example-payload.example-signature"}}}},"400":{"description":"The JSON body is malformed or an operation field is invalid.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"401":{"description":"An IAM service account was named and the request has no bearer token this instance minted.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"403":{"description":"The caller lacks roles/iam.serviceAccountTokenCreator, or an equivalent permission, on the named IAM service account or its project, or the account does not exist.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}},"500":{"description":"The local signer could not sign the token.","headers":{"Metadata-Flavor":{"description":"Set by the local metadata server.","schema":{"type":"string","const":"Google"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}}}}},"/service_accounts/v1/metadata/x509/{account}":{"get":{"tags":["Service account certificates"],"operationId":"getServiceAccountX509Certificates","summary":"Get service account certificates","description":"Returns the account’s enabled, valid public keys as PEM X.509 certificates, keyed by key ID. The system-managed key is listed first. No credentials or Metadata-Flavor header are required, matching the www.googleapis.com path.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/internal/metadata/serviceaccountcerts.go"},"parameters":[{"name":"account","in":"path","required":true,"description":"Email of a service account created through the IAM API.","schema":{"type":"string"},"example":"worker@example-project.iam.gserviceaccount.com"}],"responses":{"200":{"description":"Key IDs and PEM certificates. The example is a placeholder.","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"}},"example":{"example-key-id":"-----BEGIN CERTIFICATE-----\nexample\n-----END CERTIFICATE-----\n"}}}},"404":{"description":"The account does not exist or is not live.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}}}}},"/service_accounts/v1/metadata/jwk/{account}":{"get":{"tags":["Service account certificates"],"operationId":"getServiceAccountJwks","summary":"Get service account JSON Web Keys","description":"Returns the same keys as the x509 path as a JSON Web Key Set. No credentials or Metadata-Flavor header are required.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/internal/metadata/serviceaccountcerts.go"},"parameters":[{"name":"account","in":"path","required":true,"description":"Email of a service account created through the IAM API.","schema":{"type":"string"},"example":"worker@example-project.iam.gserviceaccount.com"}],"responses":{"200":{"description":"JWKS for the account. The example is a placeholder.","content":{"application/json":{"schema":{"type":"object","properties":{"keys":{"type":"array","items":{"$ref":"#/components/schemas/PublicSigningKey"}}},"required":["keys"]},"example":{"keys":[{"kty":"RSA","alg":"RS256","use":"sig","kid":"example-key-id","n":"example-modulus","e":"AQAB"}]}}}},"404":{"description":"The account does not exist or is not live.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}}}}},"/robot/v1/metadata/x509/{account}":{"get":{"tags":["Service account certificates"],"operationId":"getRobotX509Certificates","summary":"Get key file certificates","description":"Returns the account’s enabled, valid public keys as PEM X.509 certificates, keyed by key ID. The system-managed key is listed first. No credentials or Metadata-Flavor header are required, matching the www.googleapis.com path.","externalDocs":{"description":"Pinned CloudBurrow source","url":"https://github.com/cloudburrow/cloudburrow/blob/0ea25940d357e11a52853ca2d35617fc5253ffb0/internal/metadata/serviceaccountcerts.go"},"parameters":[{"name":"account","in":"path","required":true,"description":"Email of a service account created through the IAM API.","schema":{"type":"string"},"example":"worker@example-project.iam.gserviceaccount.com"}],"responses":{"200":{"description":"Key IDs and PEM certificates. The example is a placeholder.","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"}},"example":{"example-key-id":"-----BEGIN CERTIFICATE-----\nexample\n-----END CERTIFICATE-----\n"}}}},"404":{"description":"The account does not exist or is not live.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IamError"}}}}}}}},"components":{"schemas":{"AccessToken":{"type":"object","properties":{"access_token":{"type":"string"},"expires_in":{"type":"integer","const":3600},"token_type":{"type":"string","const":"Bearer"}},"required":["access_token","expires_in","token_type"]},"TokenExchange":{"type":"object","properties":{"grant_type":{"type":"string"},"assertion":{"type":"string","minLength":1},"refresh_token":{"type":"string","minLength":1}},"anyOf":[{"required":["assertion"]},{"required":["refresh_token"]}]},"PublicSigningKey":{"type":"object","properties":{"kty":{"type":"string","const":"RSA"},"alg":{"type":"string","const":"RS256"},"use":{"type":"string","const":"sig"},"kid":{"type":"string"},"n":{"type":"string"},"e":{"type":"string"}},"required":["kty","alg","use","kid","n","e"]},"IamError":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"integer"},"message":{"type":"string"},"status":{"type":"string"}},"required":["code","message","status"]}},"required":["error"]}}},"x-cloudburrow":{"ref":"release","sha":"0ea25940d357e11a52853ca2d35617fc5253ffb0"}}