Example #1
0
 /**
  * Put thread
  * https://cybozudev.zendesk.com/hc/ja/articles/201941894
  *
  * @param integer $id
  * @param string  $name
  * @param string  $body
  * @param integer $guestSpaceId
  * @return array
  */
 public function put($id, $name = null, $body = null, $guestSpaceId = null)
 {
     $options = ['json' => ['id' => $id]];
     if ($name !== null) {
         $options['json']['name'] = $name;
     }
     if ($body !== null) {
         $options['json']['body'] = $body;
     }
     return $this->client->put(KintoneApi::generateUrl('space/thread.json', $guestSpaceId), $options)->getBody()->jsonSerialize();
 }
Example #2
0
 /**
  * Put record status
  * https://cybozudev.zendesk.com/hc/ja/articles/204791550#anchor_changeRecordStatus
  *
  * @param integer $appId
  * @param integer $id
  * @param string $action
  * @param string $assignee
  * @param integer $guestSpaceId
  * @param integer $revision
  * @return array
  */
 public function putStatus($appId, $id, $action, $assignee = null, $guestSpaceId = null, $revision = -1)
 {
     $options = ['json' => ['app' => $appId, 'id' => $id, 'action' => $action, 'revision' => $revision]];
     if ($assignee !== null) {
         $options['json']['assignee'] = $assignee;
     }
     return $this->client->put(KintoneApi::generateUrl('record/status.json', $guestSpaceId), $options)->getBody()->jsonSerialize();
 }
Example #3
0
 /**
  * Put space guest users
  * https://cybozudev.zendesk.com/hc/ja/articles/201941904
  *
  * @param integer $id
  * @param array   $guests
  * @return array
  */
 public function putGuests($id, array $guests)
 {
     $options = ['json' => ['id' => $id, 'guests' => $guests]];
     return $this->client->put(KintoneApi::generateUrl('space/guests.json', $id), $options)->getBody()->jsonSerialize();
 }
Example #4
0
 /**
  * Put app JavaScript & CSS customize to preview app
  * https://cybozudev.zendesk.com/hc/ja/articles/204529834
  *
  * @param integer $id
  * @param array   $js
  * @param array   $css
  * @param array   $mobileJs
  * @param integer $guestSpaceId
  * @param string  $scope
  * @param integer $revision
  * @return array
  */
 public function putCustomize($id, array $js = [], array $css = [], array $mobileJs = [], $guestSpaceId = null, $scope = 'ALL', $revision = -1)
 {
     $options = ['json' => ['app' => $id, 'desktop' => ['js' => $js, 'css' => $css], 'mobile' => ['js' => $mobileJs], 'scope' => $scope, 'revision' => $revision]];
     return $this->client->put(KintoneApi::generateUrl('preview/app/customize.json', $guestSpaceId), $options)->getBody()->jsonSerialize();
 }
Example #5
0
 /**
  * Put records status
  * https://cybozudev.zendesk.com/hc/ja/articles/204791550#anchor_changeRecordStatusBulk
  *
  * @param integer $appId
  * @param array $records
  * @param integer $guestSpaceId
  * @return array
  */
 public function putStatus($appId, array $records, $guestSpaceId = null)
 {
     $options = ['json' => ['app' => $appId, 'records' => $records]];
     return $this->client->put(KintoneApi::generateUrl('records/status.json', $guestSpaceId), $options)->getBody()->jsonSerialize();
 }