REST-KnowledgeArticle
This topic provides details about the REST - KnowledgeArticle API call that GFI HelpDesk uses, including its field types, arguments, and responses.
Retrieve a list of articles identified by $categoryid$
.
Arguments
Name | Description |
---|---|
$categoryid$ | The knowledgebase category ID |
$count$ | Items count for retrieval |
$start$ | Start item for retrieval |
$sortField$ | Sort items according to a single specified field |
$sortOrder$ | Sort items according to a single specified order |
Response
<kbarticle>
<kbarticleid><![CDATA[1]]]]><![CDATA[></kbarticleid>
<contents><![CDATA[Contents]]]]>
<![CDATA[></contents><contentstext>
<![CDATA[Contents]]]]><![CDATA[>
</contentstext><categories><categoryid>
<![CDATA[0]]]]><![CDATA[></categoryid>
</categories>
<creator><![CDATA[2]]]]><![CDATA[></creator>
<creatorid><![CDATA[1]]]]><![CDATA[></creatorid>
<author><![CDATA[Simaranjit Singh]]]]><![CDATA[></author>
<email><![CDATA[email@domain.com]]]]><![CDATA[></email>
<subject><![CDATA[Subject]]]]><![CDATA[></subject>
<isedited><![CDATA[1]]]]><![CDATA[></isedited>
<editeddateline><![CDATA[1336757517]]]]><![CDATA[></editeddateline>
<editedstaffid><![CDATA[1]]]]><![CDATA[></editedstaffid>
<views><![CDATA[24]]]]><![CDATA[></views>
<isfeatured><![CDATA[0]]]]><![CDATA[></isfeatured>
<allowcomments><![CDATA[1]]]]><![CDATA[></allowcomments>
<totalcomments><![CDATA[0]]]]><![CDATA[></totalcomments>
<hasattachments><![CDATA[1]]]]><![CDATA[></hasattachments>
<attachments>
<attachment>
<id><![CDATA[4]]]]><![CDATA[></id>
<filename><![CDATA[photo.jpg]]]]><![CDATA[></filename>
<filesize><![CDATA[88.42 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
<attachment>
<id><![CDATA[5]]]]><![CDATA[></id>
<filename><![CDATA[cap_ture1.png]]]]><![CDATA[></filename>
<filesize><![CDATA[8.99 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
<attachment>
<id><![CDATA[20]]]]><![CDATA[></id>
<filename><![CDATA[abcde.txt]]]]><![CDATA[></filename>
<filesize><![CDATA[0.00 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
</attachments>
<dateline><![CDATA[1335437662]]]]><![CDATA[></dateline>
<articlestatus><![CDATA[1]]]]><![CDATA[></articlestatus>
<articlerating><![CDATA[0]]]]><![CDATA[></articlerating>
<ratinghits><![CDATA[0]]]]><![CDATA[></ratinghits>
<ratingcount><![CDATA[0]]]]><![CDATA[></ratingcount>
</kbarticle>
</kbarticles>
Retrieve a list of all articles.
Response
<kbarticle>
<kbarticleid><![CDATA[1]]]]><![CDATA[></kbarticleid>
<contents><![CDATA[Contents]]]]><![CDATA[></contents>
<contentstext><![CDATA[Contents]]]]><![CDATA[></contentstext>
<categories>
<categoryid><![CDATA[0]]]]><![CDATA[></categoryid>
</categories>
<creator><![CDATA[2]]]]><![CDATA[></creator>
<creatorid><![CDATA[1]]]]><![CDATA[></creatorid>
<author><![CDATA[Simaranjit Singh]]]]><![CDATA[></author>
<email><![CDATA[email@domain.com]]]]><![CDATA[></email>
<subject><![CDATA[Subject]]]]><![CDATA[></subject>
<isedited><![CDATA[1]]]]><![CDATA[></isedited>
<editeddateline><![CDATA[1336757517]]]]><![CDATA[></editeddateline>
<editedstaffid><![CDATA[1]]]]><![CDATA[></editedstaffid>
<views><![CDATA[24]]]]><![CDATA[></views>
<isfeatured><![CDATA[0]]]]><![CDATA[></isfeatured>
<allowcomments><![CDATA[1]]]]><![CDATA[></allowcomments>
<totalcomments><![CDATA[0]]]]><![CDATA[></totalcomments>
<hasattachments><![CDATA[1]]]]><![CDATA[></hasattachments>
<attachments>
<attachment>
<id><![CDATA[4]]]]><![CDATA[></id>
<filename><![CDATA[photo.jpg]]]]><![CDATA[></filename>
<filesize><![CDATA[88.42 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
<attachment>
<id><![CDATA[5]]]]><![CDATA[></id>
<filename><![CDATA[cap_ture1.png]]]]><![CDATA[></filename>
<filesize><![CDATA[8.99 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
<attachment>
<id><![CDATA[20]]]]><![CDATA[></id>
<filename><![CDATA[abcde.txt]]]]><![CDATA[></filename>
<filesize><![CDATA[0.00 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachments>
<dateline><![CDATA[1335437662]]]]><![CDATA[></dateline>
<articlestatus><![CDATA[1]]]]><![CDATA[></articlestatus>
<articlerating><![CDATA[0]]]]><![CDATA[></articlerating>
<ratinghits><![CDATA[0]]]]><![CDATA[></ratinghits>
<ratingcount><![CDATA[0]]]]><![CDATA[></ratingcount>
</kbarticle>
</kbarticles>
Retrieve an article identified by $id$
.
Arguments
Name | Description |
---|---|
$id$ | The unique numeric identifier of the knowledgebase article |
Response
<kbarticle>
<kbarticleid><![CDATA[1]]]]><![CDATA[></kbarticleid>
<contents><![CDATA[Contents]]]]><![CDATA[></contents>
<contentstext><![CDATA[Contents]]]]><![CDATA[></contentstext>
<categories>
<categoryid><![CDATA[0]]]]><![CDATA[></categoryid>
</categories>
<creator><![CDATA[2]]]]><![CDATA[></creator>
<creatorid><![CDATA[1]]]]><![CDATA[></creatorid>
<author><![CDATA[Simaranjit Singh]]]]><![CDATA[></author>
<email><![CDATA[email@domain.com]]]]><![CDATA[></email>
<subject><![CDATA[Subject]]]]><![CDATA[></subject>
<isedited><![CDATA[1]]]]><![CDATA[></isedited>
<editeddateline><![CDATA[1336757517]]]]><![CDATA[></editeddateline>
<editedstaffid><![CDATA[1]]]]><![CDATA[></editedstaffid>
<views><![CDATA[24]]]]><![CDATA[></views>
<isfeatured><![CDATA[0]]]]><![CDATA[></isfeatured>
<allowcomments><![CDATA[1]]]]><![CDATA[></allowcomments>
<totalcomments><![CDATA[0]]]]><![CDATA[></totalcomments>
<hasattachments><![CDATA[1]]]]><![CDATA[></hasattachments>
<attachments>
<attachment>
<id><![CDATA[4]]]]><![CDATA[></id>
<filename><![CDATA[photo.jpg]]]]><![CDATA[></filename>
<filesize><![CDATA[88.42 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link></attachment>
<attachment>
<id><![CDATA[5]]]]><![CDATA[></id>
<filename><![CDATA[cap_ture1.png]]]]><![CDATA[></filename>
<filesize><![CDATA[8.99 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
<attachment>
<id><![CDATA[20]]]]><![CDATA[></id>
<filename><![CDATA[abcde.txt]]]]><![CDATA[></filename>
<filesize><![CDATA[0.00 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
</attachments>
<dateline><![CDATA[1335437662]]]]><![CDATA[></dateline>
<articlestatus><![CDATA[1]]]]><![CDATA[></articlestatus>
<articlerating><![CDATA[0]]]]><![CDATA[></articlerating>
<ratinghits><![CDATA[0]]]]><![CDATA[></ratinghits>
<ratingcount><![CDATA[0]]]]><![CDATA[></ratingcount>
</kbarticle>
</kbarticles>
A new knowledgebase article.
Arguments (POST variables)
Name | Description |
---|---|
subject | The article subject |
contents | The article contents |
creatorid | The Staff ID |
articlestatus | Article status. 1 for published, 2 for drafts |
isfeatured | Is featured. 0 is for no and 1 is for yes |
allowcomments | Allow comments. 0 is for no and 1 is for yes |
categoryid | The article category/categories. Multiple categories can be comma separated like 1, 2, 3 |
Response
<kbarticle>
<kbarticleid><![CDATA[1]]]]><![CDATA[></kbarticleid>
<contents><![CDATA[Contents]]]]><![CDATA[></contents>
<contentstext><![CDATA[Contents]]]]><![CDATA[></contentstext>
<categories>
<categoryid><![CDATA[0]]]]><![CDATA[></categoryid>
</categories>
<creator><![CDATA[2]]]]><![CDATA[></creator>
<creatorid><![CDATA[1]]]]><![CDATA[></creatorid>
<author><![CDATA[Simaranjit Singh]]]]><![CDATA[></author>
<email><![CDATA[email@domain.com]]]]><![CDATA[></email>
<subject><![CDATA[Subject]]]]><![CDATA[></subject>
<isedited><![CDATA[1]]]]><![CDATA[></isedited>
<editeddateline><![CDATA[1336757517]]]]><![CDATA[></editeddateline>
<editedstaffid><![CDATA[1]]]]><![CDATA[></editedstaffid>
<views><![CDATA[24]]]]><![CDATA[></views>
<isfeatured><![CDATA[0]]]]><![CDATA[></isfeatured>
<allowcomments><![CDATA[1]]]]><![CDATA[></allowcomments>
<totalcomments><![CDATA[0]]]]><![CDATA[></totalcomments>
<hasattachments><![CDATA[1]]]]><![CDATA[></hasattachments>
<attachments>
<attachment>
<id><![CDATA[4]]]]><![CDATA[></id>
<filename><![CDATA[photo.jpg]]]]><![CDATA[></filename>
<filesize><![CDATA[88.42 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
<attachment>
<id><![CDATA[5]]]]><![CDATA[></id>
<filename><![CDATA[cap_ture1.png]]]]><![CDATA[></filename>
<filesize><![CDATA[8.99 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
<attachment>
<id><![CDATA[20]]]]><![CDATA[></id>
<filename><![CDATA[abcde.txt]]]]><![CDATA[></filename>
<filesize><![CDATA[0.00 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
</attachments>
<dateline><![CDATA[1335437662]]]]><![CDATA[></dateline>
<articlestatus><![CDATA[1]]]]><![CDATA[></articlestatus>
<articlerating><![CDATA[0]]]]><![CDATA[></articlerating>
<ratinghits><![CDATA[0]]]]><![CDATA[></ratinghits>
<ratingcount><![CDATA[0]]]]><![CDATA[></ratingcount>
</kbarticle>
</kbarticles>
Update knowledgebase article identified by $id$.
Arguments
Name | Description |
---|---|
editedstaffid | The staff ID |
subject | The article subject |
contents | The article contents |
articlestatus | Article status, 1 for published; 2 for draft |
isfeatured | Is featured. 0 is for no and 1 is for yes |
allowcomments | Allow comments. 0 is for no and 1 is for yes |
categoryid | The article category/categories for an article. Multiple categories can be comma separated like 1, 2, 3 |
Response
<kbarticle>
<kbarticleid><![CDATA[1]]]]><![CDATA[></kbarticleid>
<contents><![CDATA[Contents]]]]><![CDATA[></contents>
<contentstext><![CDATA[Contents]]]]><![CDATA[></contentstext>
<categories>
<categoryid><![CDATA[0]]]]><![CDATA[></categoryid>
</categories>
<creator><![CDATA[2]]]]><![CDATA[></creator>
<creatorid><![CDATA[1]]]]><![CDATA[></creatorid>
<author><![CDATA[Simaranjit Singh]]]]><![CDATA[></author>
<email><![CDATA[email@domain.com]]]]><![CDATA[></email>
<subject><![CDATA[Subject]]]]><![CDATA[></subject>
<isedited><![CDATA[1]]]]><![CDATA[></isedited>
<editeddateline><![CDATA[1336757517]]]]><![CDATA[></editeddateline>
<editedstaffid><![CDATA[1]]]]><![CDATA[></editedstaffid>
<views><![CDATA[24]]]]><![CDATA[></views>
<isfeatured><![CDATA[0]]]]><![CDATA[></isfeatured>
<allowcomments><![CDATA[1]]]]><![CDATA[></allowcomments>
<totalcomments><![CDATA[0]]]]><![CDATA[></totalcomments>
<hasattachments><![CDATA[1]]]]><![CDATA[></hasattachments>
<attachments>
<attachment>
<id><![CDATA[4]]]]><![CDATA[></id>
<filename><![CDATA[photo.jpg]]]]><![CDATA[></filename>
<filesize><![CDATA[88.42 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
<attachment>
<id><![CDATA[5]]]]><![CDATA[></id>
<filename><![CDATA[cap_ture1.png]]]]><![CDATA[></filename>
<filesize><![CDATA[8.99 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
<attachment>
<id><![CDATA[20]]]]><![CDATA[></id>
<filename><![CDATA[abcde.txt]]]]><![CDATA[></filename>
<filesize><![CDATA[0.00 KB]]]]><![CDATA[></filesize>
<link><![CDATA[http://localhost/fusiongit/trunk/api/index.php?/Knowledgebase/Article/GetAttachment/1/20]]]]><![CDATA[></link>
</attachment>
</attachments>
<dateline><![CDATA[1335437662]]]]><![CDATA[></dateline>
<articlestatus><![CDATA[1]]]]><![CDATA[></articlestatus>
<articlerating><![CDATA[0]]]]><![CDATA[></articlerating>
<ratinghits><![CDATA[0]]]]><![CDATA[></ratinghits>
<ratingcount><![CDATA[0]]]]><![CDATA[></ratingcount>
</kbarticle>
</kbarticles>
Delete a knowledgebase article identified by $id$.
Arguments
Name | Description |
---|---|
$id$ | The unique numeric identifier of the article |