Write a use-case sample pack into the project graph
POST
/api/v1/projects/{projectId}/sample-packs/{packId}
const url = 'https://api.yggy.tech/api/v1/projects/example/sample-packs/example';const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.yggy.tech/api/v1/projects/example/sample-packs/example \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” projectId
required
string
packId
required
string
Responses
Section titled “ Responses ”Pack written
Media type application/json
object
packId
required
string
documentId
required
string
entitiesCreated
required
integer
entitiesReused
required
integer
triplesCreated
required
integer
triplesReused
required
integer
Example generated
{ "packId": "example", "documentId": "example", "entitiesCreated": 1, "entitiesReused": 1, "triplesCreated": 1, "triplesReused": 1}Unauthorized
Media type application/json
object
success
required
boolean
error
required
object
message
required
string
code
required
string
details
Example
{ "success": false, "error": { "code": "INTERNAL_ERROR" }}Forbidden
Media type application/json
object
success
required
boolean
error
required
object
message
required
string
code
required
string
details
Example
{ "success": false, "error": { "code": "INTERNAL_ERROR" }}Project or sample pack not found
Media type application/json
object
success
required
boolean
error
required
object
message
required
string
code
required
string
details
Example
{ "success": false, "error": { "code": "INTERNAL_ERROR" }}