This section covers how to access the best performing messages from your tests via API as part of Naytev's Global Optimization API Service. To access the API, you'll first need to setup API Authorization

Once authorized, you can use the API to access: Post Text, Headline, Description, and Image. Below are instructions for using the API.

Get Result

  • URL:

https://api.naytev.com/v1/test/result/:url

  • Method:
GET
  • URL Params
url=[string -- UTF-8 encoded open graph url of the piece of content]
  • Success Response:Code: 200 Description: A 200 response is returned when there is a test run and there is a winner of the test Code: 204 Description: A 204 response is returned when there is not a test running or a test doesn't have a winning variant yetResponse Sample:
{
  testID : 12,
  post text: 'What do you use to enrich your content marketing?',
  headline: 'Why Use Infographics In Content Marketing? ',
  description: 'Before you hire a designer (or even create your own), here are 3 ways  an infographic can  make your content more engaging for your audience.',
  image: 'https://naytev-dark.s3.amazonaws.com/uploads/test_image_stub/fb_image/5137/top-colors.png'
}
curl https://api.naytev.com/v1/test/result/http%3A%2F%2Fblog.naytev.com%2Fwhy-use-infographics-in-content-marketing%2F --header "X-Auth-Token: ${API_KEY}$"
  • Notes: The results are cached for 30 minutes.
Did this answer your question?