Skip to content

Latest commit

 

History

History
150 lines (101 loc) · 4.44 KB

CMSPagesApi.md

File metadata and controls

150 lines (101 loc) · 4.44 KB

CMSPagesApi

All URIs are relative to https://api.kinow.com/api

Method HTTP request Description
createCMSPage POST /cms-pages
getCMSPages GET /cms-pages
updateCMSPage PUT /cms-pages/{cms_page_id}

createCMSPage

\Kinow\Client\Model\CMSPage createCMSPage($body)

Create cms page

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Kinow\Client\Api\CMSPagesApi();
$body = new \Kinow\Client\Model\CMSPage(); // \Kinow\Client\Model\CMSPage | 

try {
    $result = $api_instance->createCMSPage($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CMSPagesApi->createCMSPage: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
body \Kinow\Client\Model\CMSPage

Return type

\Kinow\Client\Model\CMSPage

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

getCMSPages

\Kinow\Client\Model\CMSPageLists getCMSPages($page, $per_page, $filters, $sort_by, $sort_direction)

Get cms pages

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Kinow\Client\Api\CMSPagesApi();
$page = 789; // int | 
$per_page = 789; // int | 
$filters = "filters_example"; // string | ```     name[value]=string&name[operator]=contains&date_add[value]=string&date_add[operator]=lt     _______________      {     \"name\": {     \"value\": \"string\",     \"operator\": \"contains\"     },     \"date_add\": {     \"value\": \"string\",     \"operator\": \"lt\"     }     } ```     Operator can be: strict, contains, between, in, gt (greater than), lt (lower than).
$sort_by = "sort_by_example"; // string | Sort by this attribute (id by default)
$sort_direction = "sort_direction_example"; // string | Sorting direction (asc by default)

try {
    $result = $api_instance->getCMSPages($page, $per_page, $filters, $sort_by, $sort_direction);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CMSPagesApi->getCMSPages: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
page int [optional]
per_page int [optional]
filters string ``` name[value]=string&name[operator]=contains&date_add[value]=string&date_add[operator]=lt _______________ { &quot;name&quot;: { &quot;value&quot;: &quot;string&quot;, &quot;operator&quot;: &quot;contains&quot; }, &quot;date_add&quot;: { &quot;value&quot;: &quot;string&quot;, &quot;operator&quot;: &quot;lt&quot; } } ``` Operator can be: strict, contains, between, in, gt (greater than), lt (lower than). [optional]
sort_by string Sort by this attribute (id by default) [optional]
sort_direction string Sorting direction (asc by default) [optional]

Return type

\Kinow\Client\Model\CMSPageLists

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

updateCMSPage

\Kinow\Client\Model\CMSPage updateCMSPage($cms_page_id, $body)

Update cms page

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Kinow\Client\Api\CMSPagesApi();
$cms_page_id = 789; // int | CMS page ID to update
$body = new \Kinow\Client\Model\CMSPage(); // \Kinow\Client\Model\CMSPage | 

try {
    $result = $api_instance->updateCMSPage($cms_page_id, $body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling CMSPagesApi->updateCMSPage: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
cms_page_id int CMS page ID to update
body \Kinow\Client\Model\CMSPage

Return type

\Kinow\Client\Model\CMSPage

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined