reposReplaceAllTopics
Replace all repository topics
Details
- Method:
PUT - Path:
/repos/{owner}/{repo}/topics - Operation ID:
repos/replace-all-topics
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"
},
"names": {
"description": "An array of topics to add to the repository. Pass one or more topics to _replace_ the set of existing topics. Send an empty array (`[]`) to clear all topics from the repository. **Note:** Topic `names` will be saved as lowercase.",
"required": true,
"location": "body",
"type": "array"
}
}Response Schema
{
"title": "Topic",
"description": "A topic aggregates entities that are related to a subject.",
"type": "object",
"properties": {
"names": {
"type": "array",
"items": {
"type": "string"
}
}
},
"required": [
"names"
]
}Usage
from ocp_agent import OCPAgent
agent = OCPAgent()
await agent.register_api('github')
# Call this tool
result = await agent.call_tool('reposReplaceAllTopics', {
# Add required parameters here
})