Formats

Relationships

Format resources have the following relationships for their records.

  • Card Pools
  • Snapshots
  • Restrictions

All Formats

Endpoint

GET /api/v3/public/formats

Request

Route

GET /api/v3/public/formats

Headers

Content-Type: application/json
Host: api-preview.netrunnerdb.com

cURL

curl -g "https://api-preview.netrunnerdb.com/api/v3/public/formats" -X GET 

Response

Simulated Response

Status

200

Headers

content-type: application/vnd.api+json; charset=utf-8

Body

{
  "data": [
    {
      "id": "eternal",
      "type": "formats",
      "attributes": {
        "name": "Eternal",
        "active_snapshot_id": "eternal_01",
        "snapshot_ids": [
          "eternal_01"
        ],
        "restriction_ids": [
          "eternal_points_list"
        ],
        "active_card_pool_id": "eternal_01",
        "active_restriction_id": "eternal_points_list",
        "updated_at": "2022-12-08T12:00:00+00:00"
      },
      "relationships": {
        "card_pools": {
          "links": {
            "related": "http://localhost:3000/api/v3/public/card_pools?filter[format_id]=eternal"
          }
        },
        "snapshots": {
          "links": {
            "related": "http://localhost:3000/api/v3/public/snapshots?filter[format_id]=eternal"
          }
        },
        "restrictions": {
          "links": {
            "related": "http://localhost:3000/api/v3/public/restrictions?filter[format_id]=eternal"
          }
        }
      },
      "links": {
        "self": "http://localhost:3000/api/v3/public/formats/eternal"
      }
    },
    {
      "id": "startup",
      "type": "formats",
      "attributes": {
        "name": "Startup",
        "active_snapshot_id": "startup_02",
        "snapshot_ids": [
          "startup_01",
          "startup_02"
        ],
        "restriction_ids": [],
        "active_card_pool_id": "startup_02",
        "active_restriction_id": null,
        "updated_at": "2022-12-08T12:00:00+00:00"
      },
      "relationships": {
        "card_pools": {
          "links": {
            "related": "http://localhost:3000/api/v3/public/card_pools?filter[format_id]=startup"
          }
        },
        "snapshots": {
          "links": {
            "related": "http://localhost:3000/api/v3/public/snapshots?filter[format_id]=startup"
          }
        },
        "restrictions": {
          "links": {
            "related": "http://localhost:3000/api/v3/public/restrictions?filter[format_id]=startup"
          }
        }
      },
      "links": {
        "self": "http://localhost:3000/api/v3/public/formats/startup"
      }
    },
    {
      "id": "standard",
      "type": "formats",
      "attributes": {
        "name": "Standard",
        "active_snapshot_id": "standard_02",
        "snapshot_ids": [
          "standard_01",
          "standard_02",
          "standard_03",
          "standard_04",
          "standard_05"
        ],
        "restriction_ids": [
          "standard_banlist",
          "standard_restricted",
          "standard_global_penalty",
          "standard_universal_faction_cost"
        ],
        "active_card_pool_id": "standard_02",
        "active_restriction_id": "standard_banlist",
        "updated_at": "2022-12-08T12:00:00+00:00"
      },
      "relationships": {
        "card_pools": {
          "links": {
            "related": "http://localhost:3000/api/v3/public/card_pools?filter[format_id]=standard"
          }
        },
        "snapshots": {
          "links": {
            "related": "http://localhost:3000/api/v3/public/snapshots?filter[format_id]=standard"
          }
        },
        "restrictions": {
          "links": {
            "related": "http://localhost:3000/api/v3/public/restrictions?filter[format_id]=standard"
          }
        }
      },
      "links": {
        "self": "http://localhost:3000/api/v3/public/formats/standard"
      }
    }
  ],
  "links": {
    "self": "http://localhost:3000/api/v3/public/formats?page%5Bnumber%5D=1&page%5Bsize%5D=20&stats%5Btotal%5D=count",
    "first": "http://localhost:3000/api/v3/public/formats?page%5Bnumber%5D=1&page%5Bsize%5D=20&stats%5Btotal%5D=count",
    "last": "http://localhost:3000/api/v3/public/formats?page%5Bnumber%5D=1&page%5Bsize%5D=20&stats%5Btotal%5D=count"
  },
  "meta": {
    "stats": {
      "total": {
        "count": 3
      }
    }
  }
}