curl --include \
     --header "Content-Type: application/json" \
     --header "Authorization: Bearer 77af10e030c4fc85fc0738fbd5a8945722c261996ae2bfb5a0e5e974d591c83f" \
  'https://api.easyship.com/pickup/v1/pickup_slots/{courier_id}'
var request = require('request');

request({
  method: 'GET',
  url: 'https://api.easyship.com/pickup/v1/pickup_slots/{courier_id}',
  headers: {
    'Content-Type': 'application/json',
    'Authorization': 'Bearer 77af10e030c4fc85fc0738fbd5a8945722c261996ae2bfb5a0e5e974d591c83f'
  }}, function (error, response, body) {
  console.log('Status:', response.statusCode);
  console.log('Headers:', JSON.stringify(response.headers));
  console.log('Response:', body);
});
require 'rubygems' if RUBY_VERSION < '1.9'
require 'rest_client'

headers = {
  :content_type => 'application/json',
  :authorization => 'Bearer 77af10e030c4fc85fc0738fbd5a8945722c261996ae2bfb5a0e5e974d591c83f'
}

response = RestClient.get 'https://api.easyship.com/pickup/v1/pickup_slots/{courier_id}', headers
puts response
from urllib2 import Request, urlopen

headers = {
  'Content-Type': 'application/json',
  'Authorization': 'Bearer 77af10e030c4fc85fc0738fbd5a8945722c261996ae2bfb5a0e5e974d591c83f'
}
request = Request('https://api.easyship.com/pickup/v1/pickup_slots/{courier_id}', headers=headers)

response_body = urlopen(request).read()
print response_body
<?php
$ch = curl_init();

curl_setopt($ch, CURLOPT_URL, "https://api.easyship.com/pickup/v1/pickup_slots/{courier_id}");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);
curl_setopt($ch, CURLOPT_HEADER, FALSE);

curl_setopt($ch, CURLOPT_HTTPHEADER, array(
  "Content-Type: application/json",
  "Authorization: Bearer 77af10e030c4fc85fc0738fbd5a8945722c261996ae2bfb5a0e5e974d591c83f"
));

$response = curl_exec($ch);
curl_close($ch);

var_dump($response);
var request = new XMLHttpRequest();

request.open('GET', 'https://api.easyship.com/pickup/v1/pickup_slots/{courier_id}');

request.setRequestHeader('Content-Type', 'application/json');
request.setRequestHeader('Authorization', 'Bearer 77af10e030c4fc85fc0738fbd5a8945722c261996ae2bfb5a0e5e974d591c83f');

request.onreadystatechange = function () {
  if (this.readyState === 4) {
    console.log('Status:', this.status);
    console.log('Headers:', this.getAllResponseHeaders());
    console.log('Body:', this.responseText);
  }
};

request.send();

Response

{
  "courier_id": "b4552ed2-ae95-4647-9746-5790bf252c7f",
  "courier_name": "UPS",
  "message": "This Courier provides a pickup service. The available time slots are shown in local time, for the coming 7 days.",
  "pickup": {
    "provider_name": "UPS",
    "provider_customer_service_phone": "+1 2345 6789",
    "slots": {
      "2017-04-25": [
        {
          "min_time": 17,
          "max_time": 21
        }
      ],
      "2017-04-26": [
        {
          "min_time": 10,
          "max_time": 13
        },
        {
          "min_time": 13,
          "max_time": 17
        },
        {
          "min_time": 17,
          "max_time": 21
        }
      ],
      "2017-04-27": [
        {
          "min_time": 10,
          "max_time": 13
        },
        {
          "min_time": 13,
          "max_time": 17
        },
        {
          "min_time": 17,
          "max_time": 21
        }
      ],
      "2017-04-28": [
        {
          "min_time": 10,
          "max_time": 13
        },
        {
          "min_time": 13,
          "max_time": 17
        },
        {
          "min_time": 17,
          "max_time": 21
        }
      ],
      "2017-04-29": [
        {
          "min_time": 10,
          "max_time": 13
        },
        {
          "min_time": 13,
          "max_time": 17
        }
      ],
      "2017-04-30": [],
      "2017-05-01": [
        {
          "min_time": 10,
          "max_time": 13
        },
        {
          "min_time": 13,
          "max_time": 17
        },
        {
          "min_time": 17,
          "max_time": 21
        },
        {
          "min_time": 23,
          "max_time": 24
        }
      ]
    }
  }
}
Language
Authorization
Header
Click Try It! to start a request and see the response here!