Retrieving Questions through API

Note: You're located in section for advanced users. Please use this section only if you're familiar with API's.

Our public API provices access to any public knowledge base content, such as questions and categories.


Use the following URL to retrieve questions:

my_account.helpjuice.com/api/questions


You can further filter and order the questions returned via Query Parameters:

Parameter
Description
Type
Default
category_id
Returns only questions under this category.
Integer
null
limit
Limits the number of questions returned. The maximum limit is 1000. If you need all your records, you'll have to use this parameter combined with page.
Integer
250
pageUseful to retrieve questions in chunks.Integer1
order
Orders the questions returned. Allowed: "name" and "updated_at".
String
position
segments[key]Shows questions with the given segmentation fields. This option accepts multiple parameters with different keys, being able to specify multiple segmentation fields. Example: "/?segments[brand]=helpjuice&segments[name]=questions"Stringnull


It's also possible to scope the questions within a specific language. To do so, just provide the desired language in the URL using the following syntax:

my_account.helpjuice.com/api/en_US/questions


Response:

[
  {
    "id":112828,
    "name":"Embedding Videos Into Your Knowledge Base",
    "views":394,
    "account_id":1885,
    "accessibility":1,
    "slug":null,
    "description":null,
    "email":"john.smith@example.com",
    "is_published":true,
    "is_juiced":false,
    "codename":"embedding-videos-into-knowledge-base",
    "language_id":1,
    "position":0,
    "created_at":"2014-11-24T20:15:53.865Z",
    "updated_at":"2016-01-23T17:00:51.389Z",
    "categories":[
      {
        "id":7732,
        "account_id":1885,
        "name":"Using Our Text Editor",
        "language_id":1,
        "accessibility":1,
        "created_at":"2014-11-19T16:30:44.994Z",
        "updated_at":"2016-03-10T14:58:21.011Z",
        "parent_id":7728,
        "lft":10312,
        "rgt":10313,
        "position":3,
        "codename":"using-our-text-editor",
        "index":0
      }]
  }
]

By default, questions will be showed in JSON format. However, it's possible to retrieve them in other 2 formats: XLS and CSV. To do so, you just need to specify the format in the URL, as follows:

my_account.helpjuice.com/api/questions.xls => to retrieve XLS spreadsheet
my_account.helpjuice.com/api/questions.csv => to retrieve a CSV file


Troubleshooting

  • Blank response: if you are not seeing any data, or you are receiving a corrupted file (in case of XLS), that's because your Knowledge Base is marked as internally only. Solution: if you are using a browser to access the data, just sign in before making the request. Otherwise, you'll need to use your Private Key (accessible under Settings > API Credentials) in a request parameter called api_key, like:
    • my_account.helpjuice.com/api/en_US/questions?api_key=MY_KEY
Was this article helpful?

Can't find what you're looking for?

Contact Support