QA

Delete

{
  "httpMethod": "DELETE",
  "action": "delete_trip",
  "body": {
    "trip_id": 17028438789525
  }
}

Update trip


17036166414334
// user wants to go on a trip
{
    "httpMethod": "POST",
    "action": "user_wants_to_go_on_trip",
    "body": {
        "user_id": 44678034438,
        "trip_id": 17028158399865
    }
}
// user is not approved for trip
{
    "httpMethod": "POST",
    "action": "user_approval",
    "body": {
        "user_id": 44678034438,
        "trip_id": 17028158399865,
        "is_approved": true
    }
}
// user does not want to go anymore
{
  "httpMethod": "POST",
  "action": "remove_user_application",
  "body": {
    "user_id": 11444479513,
    "trip_id": 17028438789525,
  }
}

Get trip

// by trip_id
{
    "httpMethod": "GET",
    "action": "get_trip_info_by_id",
    "body": {
        "trip_id": 123
    }
}

// by location
{
    "httpMethod": "GET",
    "action": "get_trip_info_by_location",
    "body": {
        "location": "London"
    }
}

// by admin_id
{
    "httpMethod": "GET",
    "action": "get_trip_info_by_admin_id",
    "body": {
        "admin_id": 12848983912
    }
}

// by user_id
{
  "httpMethod": "GET",
  "action": "get_all_trips_for_user_id",
  "body": {
    "user_id": 17853787237
  }
}

Create trip

{
    "httpMethod": "POST",
    "action": "create_trip",
    "body": {
        "admin_id": 12848983912,
        "start_date": 946684800,
        "end_date": 956684800,
        "location": "London",
        "title": "the big trip",
        "description": "is gonna be years!"
    }
}

Get email

{
  "httpMethod": "GET",
  "action": "get_email",
  "body": {
    "user_id": 38321495466
  }
}

Create account

{
  "httpMethod": "POST",
  "action": "create_user",
  "body": {
    "email": "email@email.com",
    "password": "password123!"
  }
}