1
0
mirror of https://github.com/go-gitea/gitea.git synced 2024-11-01 08:47:40 -04:00
gitea/routers/api/v1/swagger
Bo-Yi Wu 8cd46024fd
refactor(API): refactor secret creation and update functionality (#26751)
According to the GitHub API Spec:
https://docs.github.com/en/rest/actions/secrets?apiVersion=2022-11-28#create-or-update-an-organization-secret

Merge the Create and Update secret into a single API.

- Remove the `CreateSecretOption` struct and replace it with
`CreateOrUpdateSecretOption` in `modules/structs/secret.go`
- Update the `CreateOrUpdateOrgSecret` function in
`routers/api/v1/org/action.go` to use `CreateOrUpdateSecretOption`
instead of `UpdateSecretOption`
- Remove the `CreateOrgSecret` function in
`routers/api/v1/org/action.go` and replace it with
`CreateOrUpdateOrgSecret`
- Update the Swagger documentation in
`routers/api/v1/swagger/options.go` and `templates/swagger/v1_json.tmpl`
to reflect the changes in the struct names and function names

Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
2023-08-28 13:08:19 +08:00
..
action.go feat: implement organization secret creation API (#26566) 2023-08-22 11:20:34 +08:00
activity.go Add activity feeds API (#23494) 2023-04-04 21:35:31 +08:00
activitypub.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
app.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
cron.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
issue.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
key.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
misc.go Add API for Label templates (#24602) 2023-05-23 18:10:23 +08:00
nodeinfo.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
notify.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
options.go refactor(API): refactor secret creation and update functionality (#26751) 2023-08-28 13:08:19 +08:00
org.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
package.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
repo.go API endpoint for changing/creating/deleting multiple files (#24887) 2023-05-29 17:41:35 +08:00
settings.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
user.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00