renothing
1bb5393a42
fix wrong email when use gitea as OAuth2 provider ( #7640 )
when you use gitea as OAuth2 provider, the /api/v1/user should return
user primary email as identifier, which is unique in OAuth2 clients.
this patch use convert.ToUser replace all u.APIFormat in api requests,
return primary email when caller is yourself or admin.
6 years ago
Richard Mahn
8b2f7f7d67
Fixes #7023 - API Org Visibility ( #7028 )
6 years ago
Lunny Xiao
45d0e05e14
Move sdk structs to modules/structs ( #6905 )
* move sdk structs to moduels/structs
* fix tests
* fix fmt
* fix swagger
* fix vendor
6 years ago
Richard Mahn
5cd4783a34
Fixes #6881 - API users search fix ( #6882 )
6 years ago
zeripath
6ce1401eb7
Return a UserList from /api/v1/admin/users ( #6629 )
7 years ago
John Olheiser
355c701c7f
Updates to API 404 responses ( #6077 )
7 years ago
John Olheiser
1e87227163
Adds MustChangePassword to user create/edit API, defaults to true ( #6193 )
Signed-off-by: jolheiser <john.olheiser@gmail.com>
7 years ago
Shashvat Kedia
3e261feadb
New API routes added ( #5594 )
* New API routes added
* Comments added
* Build fix
* swagger_v1_json.tmpl without new line character
* Typo fix
* Code review changes
* Code review changes
* Add copyright
* Add copyright
* Add copyright
* Update per @lafriks feedback
* Update org.go
* Update user.go
* Update user.go
* make fmt
7 years ago
zeripath
6e8294a54c
Fix Swagger JSON autogeneration issues. ( #4845 )
* Fix Swagger JSON.
Remove unnecessary schema references for the forbidden and empty responses
Signed-off-by: Andrew Thornton <art27@cantab.net>
* Fix swagger API for CreateAccessToken
* Fix admin create org swagger
* Fix swagger for adminCreateRepo
* More swagger fixes
Set int64 format for those which are int64
Some more form fixes
* Fix swagger description of GET /repos/{owner}/{repo}/pulls
7 years ago
EnricoFerro
0f0cc3e617
API /admin/users/{username} missing parameter ( #4775 )
7 years ago
Kim "BKC" Carlbäcker
fb25c73752
Cleanup models.User.HashPassword ( #3334 )
8 years ago
Morgan Bazalgette
548da9750c
Change EncodePasswd to HashPassword ( #3329 )
* Change EncodePasswd to HashPassword
* Create test+benchmark for HashPassword
8 years ago
Vlad Temian
20952f1c5f
Delete a user's public key via admin api ( closes #3014 ) ( #3059 )
* Delete a user's public key via admin api
* Test admin ssh endpoint for creating a new ssh key
* Adapt public ssh key test to also test the delete operation
* Test that deleting a missing key will result in a 404
* Test that a normal user can't delete another user's ssh key
* Make DeletePublicKey return err
* Update swagger doc
8 years ago
Ethan Koenig
1df45ea8b0
Update swagger documentation ( #2899 )
* Update swagger documentation
Add docs for missing endpoints
Add documentation for request parameters
Make parameter naming consistent
Fix response documentation
* Restore delete comments
8 years ago
Antoine GIRARD
8b81ff17f5
Improve swagger doc ( #2274 )
* Add swagger comment for adminCreateOrg
* Add swagger comment for admin route
* add hook swagger doc
* Add tags
* Add auth
* Fix name of responses
* Edit name method
* Update vendor
* make generate-swagger
8 years ago
Ethan Koenig
901f1f170e
Use handlers for API authorization ( #723 )
9 years ago
Ethan Koenig
dc4990be0d
Fix permission bugs in team API ( #647 )
9 years ago
Ethan Koenig
24db8d7848
API endpoints for organization teams ( #370 )
9 years ago
Denis Denisov
820c295d94
Fix random string generator ( #384 )
* Remove unused custom-alphabet feature of random string generator
Fix random string generator
Random string generator should return error if it fails to read random data via crypto/rand
* Fixes variable (un)initialization mixed assign
Update test GetRandomString
9 years ago
Lunny Xiao
e134836804
golint fixed for routers ( #208 )
9 years ago
Sandro Santilli
827c85ad85
Fix import path of go-sdk ( #141 )
From code.gitea.io/go-sdk/gitea
To code.gitea.io/sdk/gitea
9 years ago
Sandro Santilli
cb1b3cc148
Update import paths from github.com/go-gitea to code.gitea.io ( #135 )
- Update import paths from github.com/go-gitea to code.gitea.io
- Fix import path for travis
See https://docs.travis-ci.com/user/languages/go#Go-Import-Path
9 years ago
Sandro Santilli
0daccd049a
And others
9 years ago
Sandro Santilli
6909f35ba0
More...
9 years ago
Thomas Boerger
a2f2fa9326
Replaced go-gogs-client with go-sdk imports
9 years ago
Rémy Boulanouar
9712d5ee89
Change import reference to match gitea instead of gogs ( #37 )
9 years ago
Unknwon
437ad0d136
#3515 use alert instead 500 for duplicated login source name
9 years ago
Unknwon
6e37e3f3d7
Replace convert.To with APIFormat calls
9 years ago
Robin Lambertz
9acb7a034f
Add MaxRepoCreation to EditUser API ( #2781 )
9 years ago
Richard Mahn
15f2b16568
Added Full Name to CreateUser api call ( #3333 )
9 years ago
Unknwon
3b42ab0e57
Refactor User.Id to User.ID
9 years ago
Unknwon
7b4e810eb5
#2854 fix no mail notification when issue is closed/reopened
9 years ago
Unknwon
d497e31faa
api/admin: add/remove organization team repository
10 years ago
Unknwon
8328452c5a
#1692 add admin APIs to add/remove a user from teams
10 years ago
Unknwon
d2f481e85f
Fix status code
10 years ago
Unknwon
11c481a053
Change list teams API to non-admin specific
10 years ago
Unknwon
0b2c7a6284
#1692 api: admin list and create team under organization
10 years ago
Unknwon
5b25440502
#1692 add CRUD issue APIs
- Fix go-gogs-client#10
- Related to #809
10 years ago
Unknwon
da092dd05b
Convert all API handers to use *context.APIContext
10 years ago
Unknwon
2d90be9c2e
#13 finish user and repository search
Both are possible on explore and admin panel
10 years ago
Unknwon
574a4d69e8
Rename module: middleware -> context
10 years ago
Unknwon
5d084664bc
#1692 API: admin create repo
10 years ago
Unknwon
ae4bcfa2e0
#1692 add organization APIs
10 years ago
Unknwon
a68cde1d7a
#1938 #1374 disable password change for non-local users
10 years ago
Unknwon
ad998a52b9
#2063 Ability to delete repo from admin panel
10 years ago
Unknwon
12020f4d74
APIs: admin users
10 years ago