actionsGetEnvironmentPublicKey
Get an environment public key
Details
- Method:
GET - Path:
/repos/{owner}/{repo}/environments/{environment_name}/secrets/public-key - Operation ID:
actions/get-environment-public-key
Parameters
{
"owner": {
"description": "The account owner of the repository. The name is not case sensitive.",
"required": true,
"location": "path",
"type": "string"
},
"repo": {
"description": "The name of the repository without the `.git` extension. The name is not case sensitive.",
"required": true,
"location": "path",
"type": "string"
},
"environment_name": {
"description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`.",
"required": true,
"location": "path",
"type": "string"
}
}Response Schema
{
"title": "ActionsPublicKey",
"description": "The public key used for setting Actions Secrets.",
"type": "object",
"properties": {
"key_id": {
"description": "The identifier for the key.",
"type": "string",
"example": "1234567"
},
"key": {
"description": "The Base64 encoded public key.",
"type": "string",
"example": "hBT5WZEj8ZoOv6TYJsfWq7MxTEQopZO5/IT3ZCVQPzs="
},
"id": {
"type": "integer",
"example": 2
},
"url": {
"type": "string",
"example": "https://api.github.com/user/keys/2"
},
"title": {
"type": "string",
"example": "ssh-rsa AAAAB3NzaC1yc2EAAA"
},
"created_at": {
"type": "string",
"example": "2011-01-26T19:01:12Z"
}
},
"required": [
"key_id",
"key"
]
}Usage
from ocp_agent import OCPAgent
agent = OCPAgent()
await agent.register_api('github')
# Call this tool
result = await agent.call_tool('actionsGetEnvironmentPublicKey', {
# Add required parameters here
})