curl --request GET \
--url https://api-dev.narrative.io/mappings \
--header 'Authorization: Bearer <token>'{
"records": [
{
"id": "ea9dddd2-e3ee-40b5-b03e-c3cd37c8a7f0",
"attribute_id": 1,
"created_at": "2021-12-10T00:00:00Z",
"dataset_id": 3,
"mapping": {
"type": "object_mapping",
"property_mappings": [
{
"path": "foo",
"expression": "upper(`US Kennel ID`)",
"dependencies": {
"properties": [
"US Kennel ID"
]
}
},
{
"path": "bar.baz.qux",
"expression": "weight * 10000",
"dependencies": {
"properties": [
"weight"
]
}
}
]
},
"status": "active",
"updated_at": "2021-12-10T00:00:01Z",
"created_by": 1,
"updated_by": 1,
"company_id": 100,
"scope": "global",
"source": "admin",
"derived_from": "ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0"
},
{
"id": "ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0",
"attribute_id": 1,
"created_at": "2021-12-10T00:00:00Z",
"dataset_id": 3,
"mapping": {
"type": "value_mapping",
"expression": "foo bar baz",
"dependencies": {
"properties": []
}
},
"status": "archived",
"updated_at": "2021-12-10T00:00:01Z",
"created_by": 1,
"updated_by": 2,
"company_id": 100,
"scope": "global",
"source": "admin",
"derived_from": null
}
]
}Return all mappings, both private and global.
curl --request GET \
--url https://api-dev.narrative.io/mappings \
--header 'Authorization: Bearer <token>'{
"records": [
{
"id": "ea9dddd2-e3ee-40b5-b03e-c3cd37c8a7f0",
"attribute_id": 1,
"created_at": "2021-12-10T00:00:00Z",
"dataset_id": 3,
"mapping": {
"type": "object_mapping",
"property_mappings": [
{
"path": "foo",
"expression": "upper(`US Kennel ID`)",
"dependencies": {
"properties": [
"US Kennel ID"
]
}
},
{
"path": "bar.baz.qux",
"expression": "weight * 10000",
"dependencies": {
"properties": [
"weight"
]
}
}
]
},
"status": "active",
"updated_at": "2021-12-10T00:00:01Z",
"created_by": 1,
"updated_by": 1,
"company_id": 100,
"scope": "global",
"source": "admin",
"derived_from": "ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0"
},
{
"id": "ea9dddd2-e3ee-40b5-b03e-c3cd37c8a6f0",
"attribute_id": 1,
"created_at": "2021-12-10T00:00:00Z",
"dataset_id": 3,
"mapping": {
"type": "value_mapping",
"expression": "foo bar baz",
"dependencies": {
"properties": []
}
},
"status": "archived",
"updated_at": "2021-12-10T00:00:01Z",
"created_by": 1,
"updated_by": 2,
"company_id": 100,
"scope": "global",
"source": "admin",
"derived_from": null
}
]
}Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Attribute identifier. Can be specified multiple times to retrieve mappings for multiple attributes.
Dataset identifier. Can be specified multiple times to retrieve mappings for multiple datasets.
OK
Show child attributes