Get Article By Id

Overview

  • This API allows a user to retrieve an article.

Permission

  • Agents without a user profile and customers in a portal without a default user profile only have access to articles:
    • Without any access tags
    • Without any publish views
    • With a publish view without any tags
  • Agents with a user profile and customers in a portal with a default user profile have access to articles:
    • Without any access tag
    • Without any publish views
    • With a publish view without any tags
    • With access tags included in the user profile
    • With publish views with tags included in the user profile
  • Agents with the following actions can view updates to articles currently being processed in workflows:
    • View Author Portal – allows agents to view updates to articles at any stage in a workflow
    • View Staging Portal – allows agents to view updates to articles in the Staging stage or a subsequent stage in a workflow
SecurityoAuthUser or oAuthCustomer or oAuthAnonymousCustomer
Request
path Parameters
portalID
required
number
Example: 202200000001001
articleID
required
string

The Id of the article on which operation is performed. Both numeric and alternate Id formats are supported for article Id.

Examples:
Providing readable article id.
PROD-2268
Providing numeric article id.
202200000002268
query Parameters
$lang
string

The knowledge base language used for retrieving the response. This must be a language that is made available to the user. If this parameter is not passed, then the default language of the system is used.

Enum: "en-US" "en-GB" "fr-FR" "es-ES" "it-IT" "de-DE" "nl-NL" "pt-BR" "pt-PT" "da-DK" "sv-SE" "ru-RU" "fr-CA" "zh-CN" "ja-JP" "ko-KR"
Example: $lang=en-US
$attribute
string

The fields of the article to be returned.

Enum: "articleMacro" "availabilityDate" "averageRating" "contentText" "createdByUserFullName" "lastModifiedByUserFullName" "orderNumber" "ownedBy" "ownedByUserName" "ownedByUserFullName" "suggestionType" "timesRated" "availableEditions" "articleTypeAttributes" "milestone" "all"
Example: $attribute=articleMacro
context
string

It provides information about article view context. It is used for recording self service events. If not provided, default value will be 'article_view'. Please refer user guide for providing custom article view context.

Enum: "article_view" "article_view_more_related_article" "article_view_basic_search" "article_view_adv_search" "article_view_guided_help" "article_view_browse_topic" "article_view_browse_tree" "article_view_dfaq" "article_view_useful_items" "article_view_widget" "article_view_announcement" "article_view_bookmarked" "article_view_subscription_notification" "article_view_guided_help_additional_info" "view_articles_pending_compliance" "type_ahead_suggestion" "semantic_suggestion" "instant_answer" "instant_answer_reference"
Example: context=article_view
edition
string

The Id of a edition for the article. Both numeric and alternate Id formats are supported.

Examples:
Providing readable edition id.
edition=PROD-2268
Providing numeric edition id.
edition=202200000002268
publishViewId
string

The Id of a publish view for the article. Both numeric and alternate Id formats are supported.

Examples:
Providing readable publish view id.
publishViewId=PROD-1234
Providing numeric publish view id.
publishViewId=202200000001234
q
string

It is used for getting the highlighting information for the searched query string.

Example: q=credit
workflowMilestone
string

For agents with the View Author Portal or View Staging Portal actions, this determines which version of the article is returned; the most recent published version or the updated version currently being processed in a workflow.

Enum: "staging" "authoring" "publish"
Example: workflowMilestone=publish
header Parameters
Accept-Language
required
string
Default: en-US

Language locale accepted by client (used for locale specific fields in resource representation and in error responses).

Enum: "en-US" "es-ES" "fr-FR" "it-IT" "de-DE" "nl-NL" "pt-BR" "pt-PT" "da-DK" "ru-RU" "fr-CA" "zh-CN" "ja-JP" "ko-KR" "sv-SE"
X-egain-tenant-id
string

Unique identifier for tenant.

X-egain-activity-id
integer

Numeric unique identifier of interaction from eGain.

X-interaction-id
string

Unique identifier for interaction from other CRM applications.

credentials
string

Required for browser to send cookies in request.

Value: "include"
Responses
200

Success

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

406

Not acceptable

500

Internal server error

get/portals/{portalID}/articles/{articleID}
Request samples
Response samples
application/json
{
  • "article": [
    ]
}