Content API Documentation

As the name suggests, contents are a core part of Pazh — the very reason Pazh exists is so you can have secure conversations with your content. On this page, we'll dive into the different contact endpoints you can use to manage content programmatically. We'll look at how to query, create, update, and delete content.


GET/v1/content

Properties

This endpoint allows you to retrieve a paginated list of all your contents. By default, a maximum of ten contents are shown per page.

  • Name
    id
    Type
    string
    Description

    identifier for the content.

  • Name
    slug
    Type
    string
    Description

    identifier for the content.

  • Name
    body
    Type
    string
    Description

    The body of the content.

  • Name
    lang
    Type
    string
    Description

    The language of the content.

  • Name
    dir
    Type
    string
    Description

    The direction of the content.

  • Name
    published
    Type
    array
    Description

    Prepared for public.

  • Name
    type
    Type
    string
    Description

    type of the content.

  • Name
    id
    Type
    string
    Description

    identifier for the content.

  • Name
    claimed
    Type
    boolean
    Description

    Show if its verified by its owner.

  • Name
    status
    Type
    string
    Description

    Situation of the content.

  • Name
    date
    Type
    string
    Description

    Time updated.

  • Name
    version
    Type
    string
    Description

    Version.

  • Name
    authorId
    Type
    string
    Description

    Identifier for the author.

Response


  {
    "id": "XXXXXXXXXXXXXXXXXXX",
    "slug":"",
    "body": "",
    "lang": "", //eng //per //arb
    "dir": "rtl", //rtl //ltr
    "published":[
      {
        "type": "",
        "id": "XXXXXXXXXXXXXXXXXXX"
      }
    ],
    "claimed": true,
    "status": "deleted",
    "date": "2023-02-15T12:50:30",
    "version": "1",
    "authorId": ""
  }


GET/v1/XXXXXXXXXXXXXXXXXXX

List all Content

This endpoint allows you to retrieve a paginated list of all your contents. By default, a maximum of ten contents are shown per page.

Optional attributes

  • Name
    limit
    Type
    integer
    Description

    Limit the number of content returned.

Request

GET
/v1/content
curl -G https://content.contentapi.io/v1/content \
  -H "Authorization: Bearer {token}" \
  -d active=true \
  -d limit=10