Skip to content

Instantly share code, notes, and snippets.

@dbulgakov
Last active April 8, 2017 16:58
Show Gist options
  • Select an option

  • Save dbulgakov/9fc0906ab36ab8fcc9d321a14cf8039d to your computer and use it in GitHub Desktop.

Select an option

Save dbulgakov/9fc0906ab36ab8fcc9d321a14cf8039d to your computer and use it in GitHub Desktop.

Revisions

  1. dbulgakov renamed this gist Apr 8, 2017. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  2. dbulgakov renamed this gist Apr 8, 2017. 1 changed file with 6 additions and 6 deletions.
    12 changes: 6 additions & 6 deletions gistfile1.txt → some.json
    Original file line number Diff line number Diff line change
    @@ -2,15 +2,15 @@ Request
    POST api/registration
    json body:
    {
    user_name : "Ivan"
    user_email : "[email protected]"
    user_name : "Ivan",
    user_email : "[email protected]",
    user_password : "1234qwerQWER"
    }

    Response
    json body:
    {
    status_code : 200
    status_code : 200,
    message : "Registration success"
    }

    @@ -20,15 +20,15 @@ Request
    POST api/login
    json body:
    {
    user_email : "[email protected]"
    user_email : "[email protected]",
    user_password : "1234qwerQWER"
    }

    Response
    json body:
    {
    status_code : 200
    message : "Login success"
    status_code : 200,
    message : "Login success",
    "data" :
    {
    user_token : "ASMDLFMLKaksfmmkqmwkleOREOEORO2M340019MASDFWQEJRJQWRE19MADSKFMKADSFMK2"
  3. dbulgakov revised this gist Apr 8, 2017. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -11,7 +11,7 @@ Response
    json body:
    {
    status_code : 200
    message = "Registration success"
    message : "Registration success"
    }

    =================================================================
    @@ -28,7 +28,7 @@ Response
    json body:
    {
    status_code : 200
    message = "Login success"
    message : "Login success"
    "data" :
    {
    user_token : "ASMDLFMLKaksfmmkqmwkleOREOEORO2M340019MASDFWQEJRJQWRE19MADSKFMKADSFMK2"
  4. dbulgakov created this gist Apr 8, 2017.
    72 changes: 72 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,72 @@
    Request
    POST api/registration
    json body:
    {
    user_name : "Ivan"
    user_email : "[email protected]"
    user_password : "1234qwerQWER"
    }

    Response
    json body:
    {
    status_code : 200
    message = "Registration success"
    }

    =================================================================

    Request
    POST api/login
    json body:
    {
    user_email : "[email protected]"
    user_password : "1234qwerQWER"
    }

    Response
    json body:
    {
    status_code : 200
    message = "Login success"
    "data" :
    {
    user_token : "ASMDLFMLKaksfmmkqmwkleOREOEORO2M340019MASDFWQEJRJQWRE19MADSKFMKADSFMK2"
    }
    }

    =================================================================

    Request
    GET api/conferences?cityId=123page=1&lang=ru // 1 page = 20 conferences
    + user token in header

    Response
    json body:
    {
    status_code : 200,
    message : "OK",
    "data" :
    {
    conferences :
    [
    {
    title : "Some conf title"
    description : "Short description"
    start_date : "12.05.2017"
    end_date : "14.05.2017"
    conference_id : 123456
    attendees : "500-1000"
    },
    {
    title : "Some conf title2"
    description : "Short description2"
    start_date : "13.05.2017"
    end_date : "13.05.2017"
    conference_id : 123457
    attendees : "<100"
    }
    ],
    pages : 10
    }
    }