Fork an article
  • 02 Feb 2022
  • 1 Minute to read
  • Contributors
  • Dark
    Light

Fork an article

  • Dark
    Light

PUT /articles/{id}/fork 

Forks an article with an ID


Header

ParameterTypeDescription
api_tokenstringYou can get the REST API from Settings > Advanced > API tokens.


Route Parameters

ParameterRequiredTypeDescription
idYesstringID of the article


Body Parameters

ParameterRequiredTypeDescription
version_numberYesstringThe version number to be forked
user_idYesstringThe ID of the user that will be marked as an author of this fork
lang_codeYesstringLanguage code for multilingual


Sample Request

{
    "version_number": 1,
    "user_id": "5ae331f74e60146b233558c6",
    "lang_code": "en"
}

Response Sample

{
    "data": {
        "version_number": 2,
        "created_by": "5ae331f74e60146b233558c6",
        "created_at": "2019-02-27T17:46:21.41088Z",
        "modified_at": "2019-02-27T17:46:21.41088Z",
        "base_version": 1,
        "status": 0,
        "profile_url": "https://s.gravatar.com/avatar/1b7c898ca4afb6c3ca5b7ccf89adc5a9.png"
    },
    "extension_data": null,
    "context": null,
    "success": true,
    "errors": [],
    "warnings": [],
    "information": []
}


Response Data

ParameterTypeDescription
version_numbernumberThe version number of the article
created_bystringAuthor name
created_atstringThe date this version was created
modified_atDateTimeThe last time the version was modified
base_versionnumberThe version number from which this version is derived
statusnumberThe status of the article: 0 - Draft, 3 - Published
profile_urlstringAuthor profile image

Was this article helpful?