Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Merged the old 2101 endpoint into this one


Excerpt

Fetch all sets of terms


Endpoint ID:2100
Method:

Status
colourGreen
titleGET

URL:

/permissions/terms/{termsID}


termsIDOPTIONAL: A GUID string identifier for the terms
Request body:None


Span
stylewhite-space: nowrap
Response body:


JSON data with information about terms.

Code Block
titleExample 1 /permissions/terms – Two terms exists
{
    "terms": [
        {
            "id": "7a6776a3-9411-4d34-9866-99aa9ac7cc27",
            "name": "Some terms",
            "description": "This explains everything",
            "text": "",
            "versions": [
                {
                    "version": "1.0",
                    "state": "draft",
 
                  "text": "Please accept our terms and conditions"
                }
            ]
        },
        {
            "id": "1f788c79-7dde-407f-a976-6b08ffb4c75a",
            "name": "Some other terms",
            "description": "This explains these terms",
            "textversions": "Please accept our terms and conditions [
                {
                    "version": "2.0",
            "versions": [        "state": "active"
                },
                {
                    "version": "21.0",
                    "state": "active",obsolete"
                }
         "text": "Please accept our terms and conditions"   ]
        }
    ]
}


Code Block
title/terms/permission – No terms exists
{
    "terms": []
}


Note

When a termsID parameter is included in the request, an empty terms array will never be returned - either the requested terms object will be returned, or a 404 response.


Code Block
title/permissions/terms/7a6776a3-9411-4d34-9866-99aa9ac7cc27 – Specific terms found
{
    "terms": [
        {
 {           "id": "7a6776a3-9411-4d34-9866-99aa9ac7cc27",
            "versionname": "1.0Some terms",
            "description": "This explains everything",
            "stateversions": "obsolete", [
                {
                    "textversion": "Accept our terms and conditions"1.0",
                    "state": "draft"
  }             ] }
       }     ]
}
Code Block
titleExample 2 – No terms exists
{        }
    "terms": []
}


Status codes:200OK

404Terms not found - only returned when a termsID parameter is included in the request