mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-25 11:22:16 +00:00
feat(API): update and delete secret for managing organization secrets (#26660)
- Add `UpdateSecret` function to modify org or user repo secret - Add `DeleteSecret` function to delete secret from an organization - Add `UpdateSecretOption` struct for updating secret options - Add `UpdateOrgSecret` function to update a secret in an organization - Add `DeleteOrgSecret` function to delete a secret in an organization GitHub API 1. Update Org Secret: https://docs.github.com/en/rest/actions/secrets?apiVersion=2022-11-28#create-or-update-an-organization-secret 2. Delete Org Secret: https://docs.github.com/en/rest/actions/secrets?apiVersion=2022-11-28#delete-an-organization-secret --------- Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
This commit is contained in:
parent
7e30986667
commit
b62c8e7765
6 changed files with 272 additions and 1 deletions
|
@ -25,3 +25,12 @@ type CreateSecretOption struct {
|
|||
// Data of the secret to create
|
||||
Data string `json:"data" binding:"Required"`
|
||||
}
|
||||
|
||||
// UpdateSecretOption options when updating secret
|
||||
// swagger:model
|
||||
type UpdateSecretOption struct {
|
||||
// Data of the secret to update
|
||||
//
|
||||
// required: true
|
||||
Data string `json:"data" binding:"Required"`
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue