Skip to content

Files

Latest commit

 

History

History
91 lines (69 loc) · 815 Bytes

README.md

File metadata and controls

91 lines (69 loc) · 815 Bytes

go-zero-devops

deploy with docker-compose

cd deploy && docker compose up -d

API example

Default Response

{
  "ok": true,
  "error": ""
}

Login

  • Api: /login
  • Method: POST
  • RequestBody:
{
  "username": "",
  "password": ""
}

Add user

  • Api: /users
  • Method: POST
  • RequestBody:
{
  "username": "",
  "password": ""
}

Delete user

  • Api: /users/id/:id
  • Method: DELETE

Update user

  • Api: /users/id/:id
  • Method: PUT
{
  "username": "",
  "password": ""
}

Get user

  • Api: /users/id/:id
  • Method: GET
  • Response:
{
  "id": 0,
  "username": "",
  "password": ""
  }

Get all user

  • Api: /users
  • Method: GET
  • Response:
[
{
  "id": 0,
  "username": "",
  "password": ""
  }
]