Skip to content

Latest commit

 

History

History
336 lines (163 loc) · 8.35 KB

File metadata and controls

336 lines (163 loc) · 8.35 KB

User data service API

Informations

Version

1.0

Contact

Content negotiation

URI Schemes

  • http

Consumes

  • application/json

Produces

  • application/json

All endpoints

auth

Method URI Name Summary
POST /api/v1/auth/login login Принимает данные пользователя для входа в систему
POST /api/v1/auth/register register Принимает данные пользователя

save_c_s_v

Method URI Name Summary
POST /api/v1/face_model/save_features save csv Принимает csv файл с фичами из видео

Paths

Принимает данные пользователя для входа в систему (login)

POST /api/v1/auth/login

Parameters

Name Source Type Go type Separator Required Default Description
user_credentials body LoginBody LoginBody Данные для логина

All responses

Code Status Description Has headers Schema
200 OK OK schema
400 Bad Request Bad Request schema

Responses

200 - OK

Status: OK

Schema

LoginOKBody

400 - Bad Request

Status: Bad Request

Schema

LoginBadRequestBody

Inlined models

LoginBadRequestBody

Properties

Name Type Go type Required Default Description Example
code integer int64 Код ошибки 26002
message string string Сообщение ошибки entity not found
name string string Наименование ошибки NotFound
status integer int64 Статус код ответа 404

LoginBody

Properties

Name Type Go type Required Default Description Example
login string string
password string string

LoginOKBody

Properties

Name Type Go type Required Default Description Example
get_face_model_url string string
upload_face_model_features_url string string

Принимает данные пользователя (register)

POST /api/v1/auth/register

Parameters

Name Source Type Go type Separator Required Default Description
user_data body RegisterBody RegisterBody Данные для регистрации

All responses

Code Status Description Has headers Schema
204 No Content No Content schema
400 Bad Request Bad Request schema

Responses

204 - No Content

Status: No Content

Schema
400 - Bad Request

Status: Bad Request

Schema

RegisterBadRequestBody

Inlined models

RegisterBadRequestBody

Properties

Name Type Go type Required Default Description Example
code integer int64 Код ошибки 26002
message string string Сообщение ошибки entity not found
name string string Наименование ошибки NotFound
status integer int64 Статус код ответа 404

RegisterBody

Properties

Name Type Go type Required Default Description Example
login string string
name string string
password string string
surname string string

Принимает csv файл с фичами из видео (save csv)

POST /api/v1/face_model/save_features

Parameters

Name Source Type Go type Separator Required Default Description
file formData file io.ReadCloser Загружаемый csv

All responses

Code Status Description Has headers Schema
204 No Content No Content schema
400 Bad Request Bad Request schema

Responses

204 - No Content

Status: No Content

Schema
400 - Bad Request

Status: Bad Request

Schema

SaveCsvBadRequestBody

Inlined models

SaveCsvBadRequestBody

Properties

Name Type Go type Required Default Description Example
code integer int64 Код ошибки 26002
message string string Сообщение ошибки entity not found
name string string Наименование ошибки NotFound
status integer int64 Статус код ответа 404

Models

app_errors.AppError

Properties

Name Type Go type Required Default Description Example
code integer int64 Код ошибки 26002
message string string Сообщение ошибки entity not found
name string string Наименование ошибки NotFound
status integer int64 Статус код ответа 404

fixtures.LoginRequest

Properties

Name Type Go type Required Default Description Example
login string string
password string string

fixtures.LoginResponse

Properties

Name Type Go type Required Default Description Example
get_face_model_url string string
upload_face_model_features_url string string

fixtures.RegisterRequest

Properties

Name Type Go type Required Default Description Example
login string string
name string string
password string string
surname string string