{
  "auth": {
    "bearer": [
      {
        "key": "token",
        "type": "string",
        "value": "{{test_key}}"
      }
    ],
    "type": "bearer"
  },
  "event": [
    {
      "listen": "prerequest",
      "script": {
        "exec": [
          "pm.collectionVariables.set('period', new Date().toISOString().slice(0, 7));"
        ],
        "type": "text/javascript"
      }
    }
  ],
  "info": {
    "description": "Try the real API with a test key. No billing setup or storage account needed. Generated from api/openapi.yaml (SHA-256 afd8a88bec901ed7b29be5a78e46309858b310d4871419fcaa97f659a81613c7).",
    "name": "Silken API sandbox",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
  },
  "item": [
    {
      "name": "Validate a native job and quote reservation ceilings without creating it",
      "request": {
        "body": {
          "mode": "raw",
          "options": {
            "raw": {
              "language": "json"
            }
          },
          "raw": "{\n  \"input_url\": \"{{base_url}}/_silken/onboarding/sample-v2.mp4\",\n  \"max_output_seconds\": 13,\n  \"profile\": \"hdr_to_sdr_1080p\",\n  \"speed\": \"standard\"\n}"
        },
        "description": "Validate a native job and quote reservation ceilings without creating it",
        "header": [
          {
            "key": "Content-Type",
            "value": "application/json"
          }
        ],
        "method": "POST",
        "url": "{{base_url}}/v1/jobs/quote"
      }
    },
    {
      "event": [
        {
          "listen": "test",
          "script": {
            "exec": [
              "pm.test('Sandbox accepted', () =\u003e { pm.response.to.have.status(201); pm.expect(pm.response.json().test_mode).to.eql(true); });",
              "if (pm.response.code === 201) pm.collectionVariables.set('job_id', pm.response.json().id);"
            ],
            "type": "text/javascript"
          }
        }
      ],
      "name": "Submit a transcode job",
      "request": {
        "body": {
          "mode": "raw",
          "options": {
            "raw": {
              "language": "json"
            }
          },
          "raw": "{\n  \"input_url\": \"{{base_url}}/_silken/onboarding/sample-v2.mp4\",\n  \"max_output_seconds\": 13,\n  \"profile\": \"hdr_to_sdr_1080p\",\n  \"speed\": \"standard\"\n}"
        },
        "description": "Submit a transcode job",
        "header": [
          {
            "key": "Content-Type",
            "value": "application/json"
          },
          {
            "key": "Idempotency-Key",
            "value": "sandbox-{{$guid}}"
          }
        ],
        "method": "POST",
        "url": "{{base_url}}/v1/jobs"
      }
    },
    {
      "name": "Get a transcode job",
      "request": {
        "description": "Get a transcode job",
        "header": [],
        "method": "GET",
        "url": "{{base_url}}/v1/jobs/{{job_id}}"
      }
    },
    {
      "name": "Download a completed sandbox output before its expiry",
      "request": {
        "description": "Download a completed sandbox output before its expiry",
        "header": [],
        "method": "GET",
        "url": "{{base_url}}/v1/jobs/{{job_id}}/output"
      }
    },
    {
      "name": "Usage for an accounting period, split per profile",
      "request": {
        "description": "Usage for an accounting period, split per profile",
        "header": [],
        "method": "GET",
        "url": "{{base_url}}/v1/usage?period={{period}}"
      }
    }
  ],
  "variable": [
    {
      "key": "base_url",
      "value": "https://silken.io"
    },
    {
      "key": "test_key",
      "value": "sk_test_REPLACE_ME"
    },
    {
      "key": "job_id",
      "value": ""
    },
    {
      "key": "period",
      "value": ""
    }
  ]
}
