{"_id":"54f0a1a56c663623001da073","user":"54ee203467e09c230091e70c","version":{"_id":"54ee20645f63b321008be94a","project":"54ee20635f63b321008be947","__v":5,"createdAt":"2015-02-25T19:20:04.054Z","releaseDate":"2015-02-25T19:20:04.054Z","categories":["54ee20645f63b321008be94b","54f097ed7d40be370012d4f1","54f097f39502520d00d78da3","54f097fcf68da9350094ec6e","54f22e183fcd560d00003ed8"],"is_deprecated":false,"is_hidden":false,"is_beta":true,"is_stable":true,"codename":"","version_clean":"1.0.0","version":"1.0"},"__v":3,"editedParams":true,"category":{"_id":"54f097fcf68da9350094ec6e","pages":["54f099589502520d00d78da6","54f0a1826c663623001da071","54f0a1a56c663623001da073","54f0a1b96c663623001da075","54f0a1d77d40be370012d500","54f0a1e96c663623001da077","54f0a20c9502520d00d78dbb","54f209253d28920d0095acba"],"version":"54ee20645f63b321008be94a","__v":8,"project":"54ee20635f63b321008be947","sync":{"url":"","isSync":false},"reference":false,"createdAt":"2015-02-27T16:14:52.485Z","from_sync":false,"order":1,"slug":"api-docs","title":"API Docs"},"editedParams2":true,"project":"54ee20635f63b321008be947","updates":[],"next":{"pages":[],"description":""},"createdAt":"2015-02-27T16:56:05.430Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[]},"method":"post","auth":"required","params":[{"_id":"54f22a493d28920d0095acc8","ref":"","in":"body","required":false,"desc":"ID of the recommender subgraph from which to generate recommendations.","default":"","type":"string","name":"subgraph"},{"_id":"54f22a8232242e0d007861a4","ref":"","in":"body","required":false,"desc":"Array of targets to be inserted","default":"","type":"array_mixed","name":"entities"}],"url":"/subgraphs/:sugraph/data/targets/"},"isReference":false,"order":3,"body":"Request body\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"{\\n    \\\"entities\\\": [\\n        {\\n            \\\"id\\\": \\\"tt0398286\\\",\\n            \\\"properties\\\": [ \\n                {\\n                    \\\"key\\\": \\\"title\\\",\\n                    \\\"value\\\": \\\"Tangled\\\"\\n                }\\n            ]\\n        }\\n    ]\\n}\",\n      \"language\": \"text\"\n    }\n  ]\n}\n[/block]","excerpt":"Insert target entities into the subgraph. If entities already exist, they will be updated. For bulk data loading, use the CSV endpoint.","slug":"create-targets","type":"endpoint","title":"Create target(s)"}

postCreate target(s)

Insert target entities into the subgraph. If entities already exist, they will be updated. For bulk data loading, use the CSV endpoint.

Definition

{{ api_url }}{{ page_api_url }}

Parameters

Body Params

subgraph:
string
ID of the recommender subgraph from which to generate recommendations.
entities:
array of mixed
Array of targets to be inserted

Documentation

Request body [block:code] { "codes": [ { "code": "{\n \"entities\": [\n {\n \"id\": \"tt0398286\",\n \"properties\": [ \n {\n \"key\": \"title\",\n \"value\": \"Tangled\"\n }\n ]\n }\n ]\n}", "language": "text" } ] } [/block]

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}