{
  "version": 1,
  "collections": [
    {
      "id": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "name": "curl",
      "color": "#0a9edc"
    }
  ],
  "snippets": [
    {
      "id": "f9dc8823-01a7-5b87-8d14-12bba9b28d80",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "GET, showing response headers",
      "body": "curl -i {{url}}",
      "description": "",
      "tags": [
        "requests"
      ]
    },
    {
      "id": "7ccf9903-2c59-550e-94ce-de251258d8b8",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Headers only",
      "body": "curl -I {{url}}",
      "description": "",
      "tags": [
        "requests"
      ]
    },
    {
      "id": "a6da7191-3dce-57be-a915-a4b98079d159",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Follow redirects",
      "body": "curl -L {{url}}",
      "description": "",
      "tags": [
        "requests"
      ]
    },
    {
      "id": "9c36a210-7b23-5357-9ebd-0999dfac921c",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "POST JSON",
      "body": "curl -X POST {{url}} \\\n  -H \"Content-Type: application/json\" \\\n  -d '{{json}}'",
      "description": "",
      "tags": [
        "requests"
      ]
    },
    {
      "id": "45861384-b58e-5211-8a67-e9fe07e4157b",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "POST JSON from a file",
      "body": "curl -X POST {{url}} -H \"Content-Type: application/json\" --data @{{file:body.json}}",
      "description": "",
      "tags": [
        "requests"
      ]
    },
    {
      "id": "b0fb7d90-61de-5c71-9cef-285f2af43795",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "PUT, PATCH or DELETE",
      "body": "curl -X {{method:PUT|PATCH|DELETE}} {{url}}",
      "description": "",
      "tags": [
        "requests"
      ]
    },
    {
      "id": "353240cf-2e43-535e-b4ae-07bbdafc1e22",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Send form fields",
      "body": "curl -d \"{{field}}={{value}}\" {{url}}",
      "description": "",
      "tags": [
        "requests"
      ]
    },
    {
      "id": "8742b261-92ec-506a-8e7a-8ca9f5934948",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Upload a file",
      "body": "curl -F \"file=@{{file}}\" {{url}}",
      "description": "",
      "tags": [
        "requests"
      ]
    },
    {
      "id": "66d179cf-5dc9-5d42-9707-29af68aae7e0",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Pretty-print a JSON response",
      "body": "curl -s {{url}} | jq",
      "description": "",
      "tags": [
        "requests"
      ]
    },
    {
      "id": "a3ce0cf2-5145-560c-a320-c8ba95a209a0",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Bearer token",
      "body": "curl {{url}} -H \"Authorization: Bearer {{token}}\"",
      "description": "",
      "tags": [
        "auth"
      ]
    },
    {
      "id": "1c82f71b-4c27-5927-8b2d-50b30ee68102",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Basic auth",
      "body": "curl -u {{user}} {{url}}",
      "description": "Asks for the password, so it isn’t left in your shell history.",
      "tags": [
        "auth"
      ]
    },
    {
      "id": "898de1ad-248b-5833-a61d-cd7b3107ad3b",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Keep cookies between requests",
      "body": "curl -c cookies.txt -b cookies.txt {{url}}",
      "description": "",
      "tags": [
        "auth"
      ]
    },
    {
      "id": "a95daa30-f3f7-5fdb-b3f4-4877b5e8e0b2",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Download to a file",
      "body": "curl -L -o {{file}} {{url}}",
      "description": "",
      "tags": [
        "downloads"
      ]
    },
    {
      "id": "cec1f998-9b60-5ba8-b9ea-5ef170cd52e7",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Download, keeping the remote name",
      "body": "curl -LO {{url}}",
      "description": "",
      "tags": [
        "downloads"
      ]
    },
    {
      "id": "d149b5f8-efbc-5757-ac83-b3d95773c594",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Resume a download",
      "body": "curl -L -C - -O {{url}}",
      "description": "",
      "tags": [
        "downloads"
      ]
    },
    {
      "id": "ba187f41-8169-5730-88b9-f77faefa3082",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Show everything sent and received",
      "body": "curl -v {{url}}",
      "description": "",
      "tags": [
        "debugging"
      ]
    },
    {
      "id": "664e4cdb-7615-506b-844d-7156c5a35c16",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Just the status code",
      "body": "curl -o /dev/null -s -w '%{http_code}\\n' {{url}}",
      "description": "",
      "tags": [
        "debugging"
      ]
    },
    {
      "id": "453e5ee5-f6c1-5d75-9033-a158cd2047b0",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Where a request spends its time",
      "body": "curl -o /dev/null -s -w 'dns %{time_namelookup}s  connect %{time_connect}s  tls %{time_appconnect}s  first byte %{time_starttransfer}s  total %{time_total}s\\n' {{url}}",
      "description": "",
      "tags": [
        "debugging"
      ]
    },
    {
      "id": "9bda7652-e677-55fd-9569-2657f6c2b0ed",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Send a request to a specific IP",
      "body": "curl --resolve {{host}}:{{port:443}}:{{ip}} https://{{host}}/",
      "description": "Test a new server before DNS points at it.",
      "tags": [
        "debugging"
      ]
    },
    {
      "id": "83409cde-e0f0-59e1-8d15-93d65d1cd359",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Ignore certificate errors",
      "body": "curl -k {{url}}",
      "description": "Only for testing.",
      "tags": [
        "debugging"
      ]
    },
    {
      "id": "408f559a-cef9-564c-8e60-6fbe509267df",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Give up after a few seconds",
      "body": "curl --max-time {{seconds:10}} {{url}}",
      "description": "",
      "tags": [
        "debugging"
      ]
    },
    {
      "id": "0bf63d46-3e92-59a2-bd43-5dc387d85529",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Retry on failure",
      "body": "curl --retry {{count:3}} {{url}}",
      "description": "",
      "tags": [
        "debugging"
      ]
    },
    {
      "id": "e1000e8c-5952-5887-b857-eaa616faae68",
      "collectionId": "b5f691ef-10ea-514e-96b9-2e7c869b39fc",
      "title": "Go through a proxy",
      "body": "curl -x {{proxy}} {{url}}",
      "description": "",
      "tags": [
        "debugging"
      ]
    }
  ]
}
