{
  "info": {
    "_postman_id": "9f3a6c7e-1bd1-4b21-9b56-gigaglobe-v1",
    "name": "GigaGlobe API v1",
    "description": "Official Postman collection for the GigaGlobe public REST API.\n\n**Auth:** every request sends `Authorization: Bearer {{api_key}}`.\nSet `api_key` and `base_url` in your environment (or override the collection variables) before running.\n\n**Variables**\n- `base_url` — e.g. `http://localhost:8730/api/v1` for dev, `https://api.gigaglobe.com/api/v1` for prod.\n- `api_key` — your minted key (`gg_live_pk_...` or `gg_test_pk_...`).\n- `customer_id` — opaque string identifying YOUR end-customer (≤128 chars).\n\nFull reference: https://gigaglobe.com/developers",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
  },
  "auth": {
    "type": "bearer",
    "bearer": [
      { "key": "token", "value": "{{api_key}}", "type": "string" }
    ]
  },
  "variable": [
    { "key": "base_url",    "value": "http://localhost:8730/api/v1", "type": "string" },
    { "key": "api_key",     "value": "gg_test_pk_REPLACE_ME",        "type": "string" },
    { "key": "customer_id", "value": "cust_42abc",                   "type": "string" }
  ],
  "item": [
    {
      "name": "Identity",
      "item": [
        {
          "name": "GET /me — verify key",
          "request": {
            "method": "GET",
            "header": [],
            "url": { "raw": "{{base_url}}/me", "host": ["{{base_url}}"], "path": ["me"] },
            "description": "Sanity-check your Bearer key. Returns the authenticated tenant + the key's name, prefix, scopes."
          },
          "response": []
        }
      ]
    },
    {
      "name": "Domains",
      "item": [
        {
          "name": "GET /domains — list",
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{base_url}}/domains?limit=25",
              "host": ["{{base_url}}"], "path": ["domains"],
              "query": [
                { "key": "limit", "value": "25" },
                { "key": "starting_after", "value": "", "disabled": true }
              ]
            }
          }
        },
        {
          "name": "POST /domains/search — search the price book",
          "request": {
            "method": "POST",
            "header": [{ "key": "Content-Type", "value": "application/json" }],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"query\": \"acmecorp\"\n}"
            },
            "url": { "raw": "{{base_url}}/domains/search", "host": ["{{base_url}}"], "path": ["domains", "search"] },
            "description": "Returns availability + register/renew/transfer pricing for every TLD in your price book."
          }
        },
        {
          "name": "GET /domains/{name}/availability",
          "request": {
            "method": "GET",
            "url": { "raw": "{{base_url}}/domains/acmecorp.com/availability", "host": ["{{base_url}}"], "path": ["domains", "acmecorp.com", "availability"] }
          }
        },
        {
          "name": "POST /domains — register",
          "request": {
            "method": "POST",
            "header": [
              { "key": "Content-Type", "value": "application/json" },
              { "key": "Idempotency-Key", "value": "{{$guid}}" }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"name\":        \"acmecorp.com\",\n  \"customer_id\": \"{{customer_id}}\",\n  \"years\":       2,\n  \"nameservers\": [\"ns1.gigaglobe.com\", \"ns2.gigaglobe.com\"]\n}"
            },
            "url": { "raw": "{{base_url}}/domains", "host": ["{{base_url}}"], "path": ["domains"] },
            "description": "Async — returns 202 + a pending domain. Subscribe to `domain.registered` to know when the registrar confirms."
          }
        },
        {
          "name": "GET /domains/{id}",
          "request": {
            "method": "GET",
            "url": { "raw": "{{base_url}}/domains/dom_1", "host": ["{{base_url}}"], "path": ["domains", "dom_1"] }
          }
        },
        {
          "name": "POST /domains/{id}/transfer",
          "request": {
            "method": "POST",
            "header": [{ "key": "Content-Type", "value": "application/json" }],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"customer_id\": \"{{customer_id}}\",\n  \"auth_code\":   \"epp-code-from-losing-registrar\"\n}"
            },
            "url": { "raw": "{{base_url}}/domains/acmecorp.com/transfer", "host": ["{{base_url}}"], "path": ["domains", "acmecorp.com", "transfer"] }
          }
        },
        {
          "name": "POST /domains/{id}/renew",
          "request": {
            "method": "POST",
            "header": [{ "key": "Content-Type", "value": "application/json" }],
            "body": { "mode": "raw", "raw": "{\n  \"years\": 1\n}" },
            "url": { "raw": "{{base_url}}/domains/dom_1/renew", "host": ["{{base_url}}"], "path": ["domains", "dom_1", "renew"] }
          }
        },
        {
          "name": "PATCH /domains/{id}",
          "request": {
            "method": "PATCH",
            "header": [{ "key": "Content-Type", "value": "application/json" }],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"auto_renew\":  true,\n  \"nameservers\": [\"ns1.cloudflare.com\", \"ns2.cloudflare.com\"]\n}"
            },
            "url": { "raw": "{{base_url}}/domains/dom_1", "host": ["{{base_url}}"], "path": ["domains", "dom_1"] }
          }
        }
      ]
    },
    {
      "name": "DNS records",
      "item": [
        {
          "name": "GET /domains/{id}/dns",
          "request": {
            "method": "GET",
            "url": { "raw": "{{base_url}}/domains/dom_1/dns", "host": ["{{base_url}}"], "path": ["domains", "dom_1", "dns"] }
          }
        },
        {
          "name": "POST /domains/{id}/dns — A record",
          "request": {
            "method": "POST",
            "header": [{ "key": "Content-Type", "value": "application/json" }],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"type\":  \"A\",\n  \"host\":  \"@\",\n  \"value\": \"203.0.113.10\",\n  \"ttl\":   3600\n}"
            },
            "url": { "raw": "{{base_url}}/domains/dom_1/dns", "host": ["{{base_url}}"], "path": ["domains", "dom_1", "dns"] }
          }
        },
        {
          "name": "POST /domains/{id}/dns — MX record",
          "request": {
            "method": "POST",
            "header": [{ "key": "Content-Type", "value": "application/json" }],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"type\":     \"MX\",\n  \"host\":     \"@\",\n  \"value\":    \"mail.example.com\",\n  \"priority\": 10,\n  \"ttl\":      3600\n}"
            },
            "url": { "raw": "{{base_url}}/domains/dom_1/dns", "host": ["{{base_url}}"], "path": ["domains", "dom_1", "dns"] }
          }
        },
        {
          "name": "DELETE /domains/{id}/dns/{record}",
          "request": {
            "method": "DELETE",
            "url": { "raw": "{{base_url}}/domains/dom_1/dns/dns_1", "host": ["{{base_url}}"], "path": ["domains", "dom_1", "dns", "dns_1"] }
          }
        }
      ]
    },
    {
      "name": "SSL certificates",
      "item": [
        {
          "name": "GET /ssl — list",
          "request": { "method": "GET", "url": { "raw": "{{base_url}}/ssl", "host": ["{{base_url}}"], "path": ["ssl"] } }
        },
        {
          "name": "POST /ssl — issue",
          "request": {
            "method": "POST",
            "header": [{ "key": "Content-Type", "value": "application/json" }],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"common_name\": \"app.acmecorp.com\",\n  \"cert_type\":   \"dv\",\n  \"customer_id\": \"{{customer_id}}\",\n  \"san_names\":   [\"www.app.acmecorp.com\"]\n}"
            },
            "url": { "raw": "{{base_url}}/ssl", "host": ["{{base_url}}"], "path": ["ssl"] },
            "description": "Async. Subscribe to `ssl.issued` to know when the CA finishes."
          }
        },
        {
          "name": "POST /ssl/{id}/renew",
          "request": { "method": "POST", "url": { "raw": "{{base_url}}/ssl/ssl_1/renew", "host": ["{{base_url}}"], "path": ["ssl", "ssl_1", "renew"] } }
        },
        {
          "name": "POST /ssl/{id}/reissue",
          "request": { "method": "POST", "url": { "raw": "{{base_url}}/ssl/ssl_1/reissue", "host": ["{{base_url}}"], "path": ["ssl", "ssl_1", "reissue"] } }
        }
      ]
    },
    {
      "name": "Hosting",
      "item": [
        {
          "name": "GET /hosting — list",
          "request": { "method": "GET", "url": { "raw": "{{base_url}}/hosting", "host": ["{{base_url}}"], "path": ["hosting"] } }
        },
        {
          "name": "POST /hosting — provision",
          "request": {
            "method": "POST",
            "header": [{ "key": "Content-Type", "value": "application/json" }],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"domain\":      \"acmecorp.com\",\n  \"package\":     \"starter\",\n  \"customer_id\": \"{{customer_id}}\",\n  \"username\":    \"acmecorp\"\n}"
            },
            "url": { "raw": "{{base_url}}/hosting", "host": ["{{base_url}}"], "path": ["hosting"] }
          }
        },
        {
          "name": "POST /hosting/{id}/suspend",
          "request": { "method": "POST", "url": { "raw": "{{base_url}}/hosting/hst_1/suspend", "host": ["{{base_url}}"], "path": ["hosting", "hst_1", "suspend"] } }
        },
        {
          "name": "POST /hosting/{id}/unsuspend",
          "request": { "method": "POST", "url": { "raw": "{{base_url}}/hosting/hst_1/unsuspend", "host": ["{{base_url}}"], "path": ["hosting", "hst_1", "unsuspend"] } }
        },
        {
          "name": "POST /hosting/{id}/password — rotate",
          "request": { "method": "POST", "url": { "raw": "{{base_url}}/hosting/hst_1/password", "host": ["{{base_url}}"], "path": ["hosting", "hst_1", "password"] } }
        }
      ]
    },
    {
      "name": "Billing (read-only)",
      "item": [
        { "name": "GET /orders",          "request": { "method": "GET", "url": { "raw": "{{base_url}}/orders",            "host": ["{{base_url}}"], "path": ["orders"] } } },
        { "name": "GET /orders/{id}",     "request": { "method": "GET", "url": { "raw": "{{base_url}}/orders/ord_1",      "host": ["{{base_url}}"], "path": ["orders", "ord_1"] } } },
        { "name": "GET /invoices",        "request": { "method": "GET", "url": { "raw": "{{base_url}}/invoices",          "host": ["{{base_url}}"], "path": ["invoices"] } } },
        { "name": "GET /invoices/{id}",   "request": { "method": "GET", "url": { "raw": "{{base_url}}/invoices/inv_1",    "host": ["{{base_url}}"], "path": ["invoices", "inv_1"] } } }
      ]
    },
    {
      "name": "Webhooks",
      "item": [
        {
          "name": "GET /webhooks — list",
          "request": { "method": "GET", "url": { "raw": "{{base_url}}/webhooks", "host": ["{{base_url}}"], "path": ["webhooks"] } }
        },
        {
          "name": "POST /webhooks — subscribe",
          "request": {
            "method": "POST",
            "header": [{ "key": "Content-Type", "value": "application/json" }],
            "body": {
              "mode": "raw",
              "raw": "{\n  \"url\":    \"https://your.app/gigaglobe/webhook\",\n  \"events\": [\"domain.*\", \"ssl.issued\", \"hosting.provisioned\", \"invoice.paid\"]\n}"
            },
            "url": { "raw": "{{base_url}}/webhooks", "host": ["{{base_url}}"], "path": ["webhooks"] },
            "description": "The signing secret is returned ONCE in `data.secret`. Save it to your secrets manager — we won't show it again."
          }
        },
        {
          "name": "PATCH /webhooks/{id}",
          "request": {
            "method": "PATCH",
            "header": [{ "key": "Content-Type", "value": "application/json" }],
            "body": { "mode": "raw", "raw": "{\n  \"is_active\": false\n}" },
            "url": { "raw": "{{base_url}}/webhooks/whk_1", "host": ["{{base_url}}"], "path": ["webhooks", "whk_1"] }
          }
        },
        {
          "name": "POST /webhooks/{id}/test",
          "request": { "method": "POST", "url": { "raw": "{{base_url}}/webhooks/whk_1/test", "host": ["{{base_url}}"], "path": ["webhooks", "whk_1", "test"] } }
        },
        {
          "name": "DELETE /webhooks/{id}",
          "request": { "method": "DELETE", "url": { "raw": "{{base_url}}/webhooks/whk_1", "host": ["{{base_url}}"], "path": ["webhooks", "whk_1"] } }
        }
      ]
    },
    {
      "name": "Usage",
      "item": [
        {
          "name": "GET /usage — 30-day stats",
          "request": { "method": "GET", "url": { "raw": "{{base_url}}/usage", "host": ["{{base_url}}"], "path": ["usage"] } }
        }
      ]
    }
  ]
}
