Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
hub
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Package registry
Operate
Terraform modules
Analyze
Contributor analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
thomasDOTwtf
hub
Commits
76a5ff95
Commit
76a5ff95
authored
4 months ago
by
cubicroot
Browse files
Options
Downloads
Patches
Plain Diff
document API authentication
parent
6127e692
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
README.md
+15
-0
15 additions, 0 deletions
README.md
with
15 additions
and
0 deletions
README.md
+
15
−
0
View file @
76a5ff95
...
@@ -39,6 +39,7 @@ Prodinstanz: <https://api.events.ccc.de/congress/2024/>
...
@@ -39,6 +39,7 @@ Prodinstanz: <https://api.events.ccc.de/congress/2024/>
| Kategorie | Endpunkt | GET | POST | PUT | DEL | Beschreibung |
| Kategorie | Endpunkt | GET | POST | PUT | DEL | Beschreibung |
| ---------- | ---------------------------------------- | --- | ---- | --- | --- | ----------------------------------------------------- |
| ---------- | ---------------------------------------- | --- | ---- | --- | --- | ----------------------------------------------------- |
| Auth |
`/auth/get-token`
| | x | | | Ausstellen eines API-Tokens |
| Persönlich |
`/me`
| x | | x | | eigenes Profil / Settings |
| Persönlich |
`/me`
| x | | x | | eigenes Profil / Settings |
| Persönlich |
`/me/friends`
| x | | x | x | Liste der Buddies |
| Persönlich |
`/me/friends`
| x | | x | x | Liste der Buddies |
| Persönlich |
`/me/badges`
| x | | | | Liste aller Badges/Achievements |
| Persönlich |
`/me/badges`
| x | | | | Liste aller Badges/Achievements |
...
@@ -64,6 +65,20 @@ Prodinstanz: <https://api.events.ccc.de/congress/2024/>
...
@@ -64,6 +65,20 @@ Prodinstanz: <https://api.events.ccc.de/congress/2024/>
Per POST werden neue Einträge angelegt, per PUT bestehende verändert.
Per POST werden neue Einträge angelegt, per PUT bestehende verändert.
Details zu den einzelnen Endpunkten folgen in Kürze™.
Details zu den einzelnen Endpunkten folgen in Kürze™.
### API-Beispiel mit cURL
Zuerst einen Token generieren:
```
bash
curl https://
{
API_URL
}
/api/auth/get-token
-H
"Content-Type: application/json"
-X
POST
--data
'{"username": "{USERNAME}", "passwort": "{PASSWORD}"}'
```
Mit diesem Token können dann Endpunkte aufgerufen werden die eine Authentifizierung erfordern:
```
bash
curl https://
{
API_URL
}
/api/me
-H
"Content-Type: application/json"
-H
"Authorization: Token {API_TOKEN}"
```
## Development
## Development
see
[
Development.md
](
./Development.md
)
see
[
Development.md
](
./Development.md
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment