Sorry, you need to enable JavaScript to visit this website.

Schema

Vector tiles are served in binary format which uses protocol buffers as method of serializing structured data. Image visible below shows dependencies between properties of vector tile.

Protobuf schema

Tile - represents vector tile as a whole entity. It consists of TileLayers.
TileLayer - as a part of Tile represents one of layers that can be later rendered e.g. layer which consists of all Parks, Roads, Build up areas, Points of interest.
TileFeatures - basicly geometry stored as an array which defines how does a feature look like. Also contains labels for roads or POIs.
TileValue - string, integer, floating point number or boolean value. Keys of TileLayer and tags of TileFeature creates relation between TileValue and TileFeature which includes specified TileValue (e.g. road label - TileValue - attached to road geometry - TileFeature).

Schema

Formally the structure of vector tile is described by protocol buffer schema. It allows to generate C++, Java, Python, Go, Ruby, Objective-C and C# code based on proto file. Proto file used by TomTom is compatibile with one used by Mapbox.

package vector_tile;

option optimize_for = LITE_RUNTIME;

message Tile {

    enum GeomType {
        UNKNOWN = 0;
        POINT = 1;
        LINESTRING = 2;
        POLYGON = 3;
    }

    message Value {
        optional string string_value = 1;
        optional float float_value = 2;
        optional double double_value = 3;
        optional int64 int_value = 4;
        optional uint64 uint_value = 5;
        optional sint64 sint_value = 6;
        optional bool bool_value = 7;
        extensions 8 to max;
    }

    message Feature {
        optional uint64 id = 1 [ default = 0 ];
        repeated uint32 tags = 2 [ packed = true ];
        optional GeomType type = 3 [ default = UNKNOWN ];
        repeated uint32 geometry = 4 [ packed = true ];
        optional bytes raster = 5;
    }

    message Layer {
        required uint32 version = 15 [ default = 1 ];
        required string name = 1;
        repeated Feature features = 2;
        repeated string keys = 3;
        repeated Value values = 4;
        optional uint32 extent = 5 [ default = 4096 ];

        extensions 16 to max;
    }

    repeated Layer layers = 3;

    extensions 16 to 8191;
}