TGC Information

This branch of the API deals with meta information about TGC products.

Printed Component Schema List

 GET /api/tgc/products

If you want to build an interface for uploading to TGC's printed compoonents inside of a game, then this is the API you've been looking for. Each component in the system will be returned in this result set, and it should be cached as it doesn't change that often.

 {
   "result" : [
      {
         "categories" : [
            "Boards",
            "Folding"
         ],
         "child" : {
            "create_api" : "/api/twosided",
            "name" : "Accordion Board",
            "parent_id" : "set_id"
         },
         "create_api" : "/api/twosidedset",
         "identity" : "AccordionBoard",
         "name" : "Accordion Board Set",
         "sides" : [
            {
               "label" : "Face",
               "overlay" : "/overlays/accordionboard.png",
               "field" : "face"
            },
            {
               "label" : "Back",
               "field" : "back",
               "overlay" : "/overlays/accordionboard.png"
            }
         ],
         "size" : { "pixels" : [2475, 4875] },
         "_relationships" : { "self" : "/api/tgc/products/AcordionBoard" },
      },
      ...
    }
  ],
 }

Printed Component Schema Properties

The individual components have the following properties:

categories

An array where the first element is a broad category to group components by, and each subsequent element gets more specific.

child

An optional object. If it exists it means this component is a set with child elements, like a deck with cards, or a book with pages, or a set with items.

create_api

A partial URL where you can do a POST to create a child of this object.

name

The human readable name of this child object.

parent_id

The name of the parent id for this child. Will be one of deck_id, booklet_id, book_id, and set_id.

create_api

A partial URL where you can do a POST to create this object.

identity

This must be passed to the create_api as it identifies this component to The Game Crafter.

name

The human readable name of this component.

sides

An array of the printed sides of the component. Each element in the array will also have these properties:

field

The field name for this side. It will be represented in several different forms. For example if it is called face then it will have a face_id and a has_proofed_face and a face object.

label

A human readable label for this side.

overlay

A partial URL to a transparent image that youc an overlay on top of the image you are uploading for proofing purposes.

size

A hash with an element called pixels pointing to an array where the first element is the width of the component and te second is the height, both measured in pixels.

Component Info

Depricated: Use the Component Schema API. This one will likely remain for a long time, but it will no longer be updated.

 GET /api/tgc/printedcomponents

This endpoint returns a JSON hash of printed game components. Each key in the hash is the class name for the printed component, and the properties for the component are in a sub hash:

 {
   "result" : {
      "PokerDeck" : {
         "cut_type" : "steel",
         "photo_credit" : "Time Barons",
         "finished_size" : "2.5 x 3.5 in",
         "name" : "Poker Deck",
         "description" : "Poker cards are one of two defacto standard sizes around the world, the other being Bridge cards. We also have a line of poker card sized tuck boxes that are great for use with poker cards.",
         "size" : "825x1125",
         "group" : "decks",
         "card_class" : "PokerCard",
         "price_per_sheet" : "1.66",
         "notes" : "",
         "photo_link" : null,
         "weight" : null,
         "count_per_sheet" : 18,
         "material" : "305gsm black-core matt card stock",
         "method_name" : "pokerdecks",
         "templates" : {
            "Photoshop" : "poker-card.psd",
            "PNG" : "poker-card.png",
            "Illustrator" : "poker-card.ai",
            "SVG" : "poker-card.svg"
         }
      },
      [...]
    },
  },

Printed Component Properties

cut_type

How this printed component is cut. For example, steel cut, or laser cut.

photo_credit

Where does the default product photo come from?

description

Describes the Printed Component.

size

The size of the component as a string. "width"x"height"

group

The product group this components falls in.

card_class

For decks only, the name of the

price_per_sheet

The cost to produce one sheet of the Printed Component.

notes

Any notes about the component. Limitations, frequently asked questions, detailed information.

photo_link

An optional link to be displayed with the product photo.

weight

How much one sheet of the component weighs. Many items will not have an explicit weight, like decks, where the weight depends on the number of cards in the deck.

count_per_sheet

How many components do you get per sheet?

material

What is the base material for this printed component?

method_name

Wing path fragment to access this component in the API. For example, the path /api/pokerdecks will allow you to manipulate Poker Decks.

templates

A hash of templates, by type. The base URL for a template is https://s3.amazonaws.com/www.thegamecrafter.com/templates/.

Detailed Component Info

 GET /api/tgc/printedcomponents/XXX

This endpoint returns a the properties of a particular Printed Component (XXX) as JSON hash. See "api/tgc/printedcomponents" for a list of all properties.

/api/tgc/componentgroups.

This endpoint returns a JSON hash of Component Groups. Each "Printed Component" falls into a Component Group.

  {
   "result" : {
      "booklets" : {
         "info" : "http://help.thegamecrafter.com/article/80-booklets",
         "notes" : "Due to the nature of saddle stitching booklet pages are printed 4 to a sheet. Please be sure to indicate (in the 'Page Number' field) the order that the pages should appear in your booklet. Each page must be uploaded as a separate full bleed image. A 20-page booklet takes up the thickness of 4 cards in a box.",
         "name" : "Booklets",
         "description" : "Saddle stitched manuals."
      },
      [...]
    }
  }

Component Group properties

info

A link to the help page for the Component Group.

notes

Notes about the Component Group.

name

The name of this group.

description

A description of the Component Group.

Component Group Info

GET /api/tgc/componentgroups/XXX

Depricated: Component groups will be going away in the future. Use categories instead.

This endpoint returns a the properties of a particular Component Group (XXX) as JSON hash. See "api/tgc/componentgroups" for a list of all properties.

^ Back to Top ^