photos-morelikethis
- cURL
- cURL (Windows)
- JavaScript
- Python
curl -X POST -H 'X-API-KEY: <YOUR_API_KEY>' -H 'accept: */*' -H 'content-type: application/json' 'https://media-api.geneea.com/v2/photos/ctk/recommend' -d '{
"id": "1234",
"title": "Emmanuel Macron in Germany.",
"text": "Mr. Macron visited a trade show in Munich.",
"recommendationCount": 2,
"returnObjects": true,
"returnObjectFields": ["name", "description", "url"],
"constraints": {
"likePhotoId": "P201904290731201"
},
}'
curl -X POST -H "X-API-KEY: <YOUR_API_KEY>" -H "content-type: application/json" "https://media-api.geneea.com/v2/photos/ctk/recommend" -d "{
\"id\": \"1234\",
\"title\": \"Emmanuel Macron in Germany.\",
\"text\": \"Mr. Macron visited a trade show in Munich.\",
\"recommendationCount\": 2,
\"returnObjects\": true,
\"returnObjectFields\": [\"name\", \"description\", \"url\"],
\"constraints\": {
\"likePhotoId\": \"P201904290731201\"
},
}"
const input = {
id: '1234',
title: 'Emmanuel Macron in Germany.',
text: 'Mr. Macron visited Berlin.',
recommendationCount: 2,
returnObjects: true,
returnObjectFields: ['name', 'description', 'url'],
constraints: {
likePhotoId: 'P201904290731201'
},
};
recommendPhotos(input, dataset, config).then(report);
input = {
'id': '1234',
'title': 'Emmanuel Macron in Germany.',
'text': 'Mr. Macron visited Berlin.',
'recommendationCount': 5,
'returnObjects': True,
'returnObjectFields': ['name', 'description', 'url'],
'constraints': {
'likePhotoId': 'P201904290731201'
},
};
recommendPhotos(dataset, input)