Skip to main content
PATCH
/
target-materials
/
layers
/
curl -X PATCH "https://api.atomscale.ai/target-materials/layers/" \
  -H "X-API-KEY: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "sample_id": 42,
    "layer_id": 1,
    "orientation": "111"
  }'
{
  "id": 100,
  "layer_id": 1,
  "sample_id": 42,
  "composition_string": "BaTiO3",
  "element_dict": { "Ba": 1, "Ti": 1, "O": 3 },
  "orientation": "111",
  "space_group": "P4mm",
  "mp_id": "mp-5020"
}
Updates one layer of a target material. Identify the layer by its parent target material (sample_id) and position (layer_id), and send the fields you want to change.
layer_id
integer
required
Layer position within the stack (used to identify the layer)
sample_id
integer
ID of the parent target material (used to identify the layer)
composition_string
string
Chemical composition of the layer (e.g., BaTiO3)
element_dict
object
Element counts or fractions that make up the layer
orientation
string
Crystallographic orientation of the layer
space_group
string
Space group of the layer
mp_id
string
Materials Project ID for the layer material
id
integer
Explicit record ID for the layer

Response

id
integer
Layer record ID
layer_id
integer
Layer position within the stack
sample_id
integer
ID of the parent target material
composition_string
string
Chemical composition of the layer
element_dict
object
Element counts or fractions that make up the layer
orientation
string
Crystallographic orientation of the layer
space_group
string
Space group of the layer
mp_id
string
Materials Project ID for the layer material
curl -X PATCH "https://api.atomscale.ai/target-materials/layers/" \
  -H "X-API-KEY: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "sample_id": 42,
    "layer_id": 1,
    "orientation": "111"
  }'
{
  "id": 100,
  "layer_id": 1,
  "sample_id": 42,
  "composition_string": "BaTiO3",
  "element_dict": { "Ba": 1, "Ti": 1, "O": 3 },
  "orientation": "111",
  "space_group": "P4mm",
  "mp_id": "mp-5020"
}