Create Layer

API Library Examples

from fulcrum import Fulcrum
fulcrum = Fulcrum('{token}')

obj = {
  "layer": {
    "name": "USGS Topo",
    "type": "xyz",
    "source": "http://basemap.nationalmap.gov/arcgis/rest/services/USGSTopo/MapServer/tile/{z}/{y}/{x}"
  }
}

layer = fulcrum.layers.create(obj)
print(layer['layer']['id'] + ' has been created!')
const { Client } = require('fulcrum-app');
const client = new Client('{token}');

const obj = {
  "name": "USGS Topo",
  "type": "xyz",
  "source": "http://basemap.nationalmap.gov/arcgis/rest/services/USGSTopo/MapServer/tile/{z}/{y}/{x}"
};

client.layers.create(obj)
  .then((layer) => {
    console.log(layer.id + ' has been created!');
  })
  .catch((error) => {
    console.log(error.message);
  });
# Not currently supported
Language
Authorization
Header
Click Try It! to start a request and see the response here!