Overview
This API endpoint allows you to post content to the Faqprime CMS programmatically. By making a POST request to this endpoint, you can create and publish new content on the Faqprime CMS by means of adding a question followed by adding the answer to that question.
Base URL
https: //yourdomain.myfaqprime.com/json/add-question?keypass=<keypass>&keysecret=<keysecret>
POST Params:
Field | Type | Description |
'title' | string | The title of the content. |
'content' | string | The main body of the content (optional) in HTML format. |
'categoryid' | integer | The ID of the category to which the content belongs. |
'tags' | string | Tags associated with the content separated by commas |
Response (JSON):
Field | Type | Description |
'error' | boolean | Boolean value indicating success('true'/'false'). |
'questionid' | integer | QuestionID if the operation is successful. |
'errorreason' | integer | Optional field, present only if error is true. |
'timestamp' | integer | Integer value representing the Unix timestamp. |
Example response JSON
{
"error": false,
"questionid": 123456,
"errorreason": null,
"timestamp": 1593650823
}
Posting an Answer:
Base URL:
https:// yourdomain.myfaqprime.com/json/add-answer?keypass=<keypass>&keysecret=<keysecret>
POST Params
Field | Type | Description |
'questionid' | integer | Question ID of the question on which this answer will be added. |
'content' | string | The main body of the answer in HTML format. |
Response (JSON)
Field | Type | Description |
'error' | boolean | Boolean value indicating success('true'/'false'). |
'answerid' | integer | Answer ID if the operation is successful. |
'errorreason' | integer | Optional field, present only if error is true. |
'timestamp' | integer | Integer value representing the Unix timestamp. |
Example response JSON:
{
"error": false,
"answerid": 123456,
"timestamp": 1593650823
}
Error Handling
In case of errors, the API will return an appropriate 'errorreason' with error field set to 'true' in the response JSON.
Authentication
To post the content using Faqprime CMS API, you need to include the keysecret and keypass in the URL of each request. You can obtain the API key pass and secret by signing up for an account on the Faqprime.
Please note that the API credentials should be kept secure and should not be shared publicly.