code
stringlengths
17
247k
docstring
stringlengths
30
30.3k
func_name
stringlengths
1
89
language
stringclasses
1 value
repo
stringlengths
7
63
path
stringlengths
7
153
url
stringlengths
51
209
license
stringclasses
4 values
public function getOrgs($zap_trace_span = null, $offset = null, $limit = 20, $descending = false, $org = null, $org_id = null, $user_id = null) { list($response) = $this->getOrgsWithHttpInfo($zap_trace_span, $offset, $limit, $descending, $org, $org_id, $user_id); return $response; }
Operation getOrgs List organizations @param string $zap_trace_span OpenTracing span context (optional) @param int $offset The offset for pagination. The number of records to skip. (optional) @param int $limit Limits the number of records returned. Default is `20`. (optional, default to 20) @param bool $descending descending (optional, default to false) @param string $org An organization name. Only returns organizations with this name. (optional) @param string $org_id An organization ID. Only returns the organization with this ID. (optional) @param string $user_id A user ID. Only returns organizations where this user is a member or owner. (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\Organizations|\InfluxDB2\Model\Error|object|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error|string
getOrgs
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function getOrgsWithHttpInfo($zap_trace_span = null, $offset = null, $limit = 20, $descending = false, $org = null, $org_id = null, $user_id = null) { $request = $this->getOrgsRequest($zap_trace_span, $offset, $limit, $descending, $org, $org_id, $user_id); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\Organizations'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation getOrgsWithHttpInfo List organizations @param string $zap_trace_span OpenTracing span context (optional) @param int $offset The offset for pagination. The number of records to skip. (optional) @param int $limit Limits the number of records returned. Default is `20`. (optional, default to 20) @param bool $descending (optional, default to false) @param string $org An organization name. Only returns organizations with this name. (optional) @param string $org_id An organization ID. Only returns the organization with this ID. (optional) @param string $user_id A user ID. Only returns organizations where this user is a member or owner. (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\Organizations|\InfluxDB2\Model\Error|object|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error|string, HTTP status code, HTTP response headers (array of strings)
getOrgsWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
protected function getOrgsRequest($zap_trace_span = null, $offset = null, $limit = 20, $descending = false, $org = null, $org_id = null, $user_id = null) { if ($offset !== null && $offset < 0) { throw new \InvalidArgumentException('invalid value for "$offset" when calling OrganizationsService.getOrgs, must be bigger than or equal to 0.'); } if ($limit !== null && $limit > 100) { throw new \InvalidArgumentException('invalid value for "$limit" when calling OrganizationsService.getOrgs, must be smaller than or equal to 100.'); } if ($limit !== null && $limit < 1) { throw new \InvalidArgumentException('invalid value for "$limit" when calling OrganizationsService.getOrgs, must be bigger than or equal to 1.'); } $resourcePath = '/api/v2/orgs'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // query params if ($offset !== null) { $queryParams['offset'] = ObjectSerializer::toQueryValue($offset); } // query params if ($limit !== null) { $queryParams['limit'] = ObjectSerializer::toQueryValue($limit); } // query params if ($descending !== null) { $queryParams['descending'] = ObjectSerializer::toQueryValue($descending); } // query params if ($org !== null) { $queryParams['org'] = ObjectSerializer::toQueryValue($org); } // query params if ($org_id !== null) { $queryParams['orgID'] = ObjectSerializer::toQueryValue($org_id); } // query params if ($user_id !== null) { $queryParams['userID'] = ObjectSerializer::toQueryValue($user_id); } // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('GET', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'getOrgs' @param string $zap_trace_span OpenTracing span context (optional) @param int $offset The offset for pagination. The number of records to skip. (optional) @param int $limit Limits the number of records returned. Default is &#x60;20&#x60;. (optional, default to 20) @param bool $descending (optional, default to false) @param string $org An organization name. Only returns organizations with this name. (optional) @param string $org_id An organization ID. Only returns the organization with this ID. (optional) @param string $user_id A user ID. Only returns organizations where this user is a member or owner. (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
getOrgsRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function getOrgsID($org_id, $zap_trace_span = null) { list($response) = $this->getOrgsIDWithHttpInfo($org_id, $zap_trace_span); return $response; }
Operation getOrgsID Retrieve an organization @param string $org_id The ID of the organization to get. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\Organization|\InfluxDB2\Model\Error
getOrgsID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function getOrgsIDWithHttpInfo($org_id, $zap_trace_span = null) { $request = $this->getOrgsIDRequest($org_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\Organization'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation getOrgsIDWithHttpInfo Retrieve an organization @param string $org_id The ID of the organization to get. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\Organization|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
getOrgsIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
protected function getOrgsIDRequest($org_id, $zap_trace_span = null) { // verify the required parameter 'org_id' is set if ($org_id === null || (is_array($org_id) && count($org_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $org_id when calling getOrgsID' ); } $resourcePath = '/api/v2/orgs/{orgID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($org_id !== null) { $resourcePath = str_replace( '{' . 'orgID' . '}', ObjectSerializer::toPathValue($org_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('GET', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'getOrgsID' @param string $org_id The ID of the organization to get. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
getOrgsIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function getOrgsIDMembers($org_id, $zap_trace_span = null) { list($response) = $this->getOrgsIDMembersWithHttpInfo($org_id, $zap_trace_span); return $response; }
Operation getOrgsIDMembers List all members of an organization @param string $org_id The organization ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\ResourceMembers|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error
getOrgsIDMembers
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function getOrgsIDMembersWithHttpInfo($org_id, $zap_trace_span = null) { $request = $this->getOrgsIDMembersRequest($org_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\ResourceMembers'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation getOrgsIDMembersWithHttpInfo List all members of an organization @param string $org_id The organization ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\ResourceMembers|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
getOrgsIDMembersWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
protected function getOrgsIDMembersRequest($org_id, $zap_trace_span = null) { // verify the required parameter 'org_id' is set if ($org_id === null || (is_array($org_id) && count($org_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $org_id when calling getOrgsIDMembers' ); } $resourcePath = '/api/v2/orgs/{orgID}/members'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($org_id !== null) { $resourcePath = str_replace( '{' . 'orgID' . '}', ObjectSerializer::toPathValue($org_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('GET', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'getOrgsIDMembers' @param string $org_id The organization ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
getOrgsIDMembersRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function getOrgsIDOwners($org_id, $zap_trace_span = null) { list($response) = $this->getOrgsIDOwnersWithHttpInfo($org_id, $zap_trace_span); return $response; }
Operation getOrgsIDOwners List all owners of an organization @param string $org_id The ID of the organization to list owners for. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\ResourceOwners|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error
getOrgsIDOwners
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function getOrgsIDOwnersWithHttpInfo($org_id, $zap_trace_span = null) { $request = $this->getOrgsIDOwnersRequest($org_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\ResourceOwners'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation getOrgsIDOwnersWithHttpInfo List all owners of an organization @param string $org_id The ID of the organization to list owners for. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\ResourceOwners|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
getOrgsIDOwnersWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
protected function getOrgsIDOwnersRequest($org_id, $zap_trace_span = null) { // verify the required parameter 'org_id' is set if ($org_id === null || (is_array($org_id) && count($org_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $org_id when calling getOrgsIDOwners' ); } $resourcePath = '/api/v2/orgs/{orgID}/owners'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($org_id !== null) { $resourcePath = str_replace( '{' . 'orgID' . '}', ObjectSerializer::toPathValue($org_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('GET', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'getOrgsIDOwners' @param string $org_id The ID of the organization to list owners for. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
getOrgsIDOwnersRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function patchOrgsID($org_id, $patch_organization_request, $zap_trace_span = null) { list($response) = $this->patchOrgsIDWithHttpInfo($org_id, $patch_organization_request, $zap_trace_span); return $response; }
Operation patchOrgsID Update an organization @param string $org_id The ID of the organization to get. (required) @param \InfluxDB2\Model\PatchOrganizationRequest $patch_organization_request Organization update to apply (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\Organization|\InfluxDB2\Model\Error
patchOrgsID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function patchOrgsIDWithHttpInfo($org_id, $patch_organization_request, $zap_trace_span = null) { $request = $this->patchOrgsIDRequest($org_id, $patch_organization_request, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\Organization'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation patchOrgsIDWithHttpInfo Update an organization @param string $org_id The ID of the organization to get. (required) @param \InfluxDB2\Model\PatchOrganizationRequest $patch_organization_request Organization update to apply (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\Organization|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
patchOrgsIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
protected function patchOrgsIDRequest($org_id, $patch_organization_request, $zap_trace_span = null) { // verify the required parameter 'org_id' is set if ($org_id === null || (is_array($org_id) && count($org_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $org_id when calling patchOrgsID' ); } // verify the required parameter 'patch_organization_request' is set if ($patch_organization_request === null || (is_array($patch_organization_request) && count($patch_organization_request) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $patch_organization_request when calling patchOrgsID' ); } $resourcePath = '/api/v2/orgs/{orgID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($org_id !== null) { $resourcePath = str_replace( '{' . 'orgID' . '}', ObjectSerializer::toPathValue($org_id), $resourcePath ); } // body params $_tempBody = null; if (isset($patch_organization_request)) { $_tempBody = $patch_organization_request; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['application/json'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('PATCH', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'patchOrgsID' @param string $org_id The ID of the organization to get. (required) @param \InfluxDB2\Model\PatchOrganizationRequest $patch_organization_request Organization update to apply (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
patchOrgsIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function postOrgs($post_organization_request, $zap_trace_span = null) { list($response) = $this->postOrgsWithHttpInfo($post_organization_request, $zap_trace_span); return $response; }
Operation postOrgs Create an organization @param \InfluxDB2\Model\PostOrganizationRequest $post_organization_request The organization to create. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\Organization|\InfluxDB2\Model\Error|object|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error|string
postOrgs
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function postOrgsWithHttpInfo($post_organization_request, $zap_trace_span = null) { $request = $this->postOrgsRequest($post_organization_request, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\Organization'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation postOrgsWithHttpInfo Create an organization @param \InfluxDB2\Model\PostOrganizationRequest $post_organization_request The organization to create. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\Organization|\InfluxDB2\Model\Error|object|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error|string, HTTP status code, HTTP response headers (array of strings)
postOrgsWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
protected function postOrgsRequest($post_organization_request, $zap_trace_span = null) { // verify the required parameter 'post_organization_request' is set if ($post_organization_request === null || (is_array($post_organization_request) && count($post_organization_request) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $post_organization_request when calling postOrgs' ); } $resourcePath = '/api/v2/orgs'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // body params $_tempBody = null; if (isset($post_organization_request)) { $_tempBody = $post_organization_request; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['application/json'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postOrgs' @param \InfluxDB2\Model\PostOrganizationRequest $post_organization_request The organization to create. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postOrgsRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function postOrgsIDMembers($org_id, $add_resource_member_request_body, $zap_trace_span = null) { list($response) = $this->postOrgsIDMembersWithHttpInfo($org_id, $add_resource_member_request_body, $zap_trace_span); return $response; }
Operation postOrgsIDMembers Add a member to an organization @param string $org_id The organization ID. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body User to add as member (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\ResourceMember|\InfluxDB2\Model\Error
postOrgsIDMembers
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function postOrgsIDMembersWithHttpInfo($org_id, $add_resource_member_request_body, $zap_trace_span = null) { $request = $this->postOrgsIDMembersRequest($org_id, $add_resource_member_request_body, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\ResourceMember'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation postOrgsIDMembersWithHttpInfo Add a member to an organization @param string $org_id The organization ID. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body User to add as member (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\ResourceMember|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
postOrgsIDMembersWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
protected function postOrgsIDMembersRequest($org_id, $add_resource_member_request_body, $zap_trace_span = null) { // verify the required parameter 'org_id' is set if ($org_id === null || (is_array($org_id) && count($org_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $org_id when calling postOrgsIDMembers' ); } // verify the required parameter 'add_resource_member_request_body' is set if ($add_resource_member_request_body === null || (is_array($add_resource_member_request_body) && count($add_resource_member_request_body) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $add_resource_member_request_body when calling postOrgsIDMembers' ); } $resourcePath = '/api/v2/orgs/{orgID}/members'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($org_id !== null) { $resourcePath = str_replace( '{' . 'orgID' . '}', ObjectSerializer::toPathValue($org_id), $resourcePath ); } // body params $_tempBody = null; if (isset($add_resource_member_request_body)) { $_tempBody = $add_resource_member_request_body; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['application/json'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postOrgsIDMembers' @param string $org_id The organization ID. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body User to add as member (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postOrgsIDMembersRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function postOrgsIDOwners($org_id, $add_resource_member_request_body, $zap_trace_span = null) { list($response) = $this->postOrgsIDOwnersWithHttpInfo($org_id, $add_resource_member_request_body, $zap_trace_span); return $response; }
Operation postOrgsIDOwners Add an owner to an organization @param string $org_id The ID of the organization that you want to add an owner for. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body The user to add as an owner of the organization. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\ResourceOwner|\InfluxDB2\Model\Error
postOrgsIDOwners
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function postOrgsIDOwnersWithHttpInfo($org_id, $add_resource_member_request_body, $zap_trace_span = null) { $request = $this->postOrgsIDOwnersRequest($org_id, $add_resource_member_request_body, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\ResourceOwner'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation postOrgsIDOwnersWithHttpInfo Add an owner to an organization @param string $org_id The ID of the organization that you want to add an owner for. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body The user to add as an owner of the organization. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\ResourceOwner|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
postOrgsIDOwnersWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
protected function postOrgsIDOwnersRequest($org_id, $add_resource_member_request_body, $zap_trace_span = null) { // verify the required parameter 'org_id' is set if ($org_id === null || (is_array($org_id) && count($org_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $org_id when calling postOrgsIDOwners' ); } // verify the required parameter 'add_resource_member_request_body' is set if ($add_resource_member_request_body === null || (is_array($add_resource_member_request_body) && count($add_resource_member_request_body) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $add_resource_member_request_body when calling postOrgsIDOwners' ); } $resourcePath = '/api/v2/orgs/{orgID}/owners'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($org_id !== null) { $resourcePath = str_replace( '{' . 'orgID' . '}', ObjectSerializer::toPathValue($org_id), $resourcePath ); } // body params $_tempBody = null; if (isset($add_resource_member_request_body)) { $_tempBody = $add_resource_member_request_body; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['application/json'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postOrgsIDOwners' @param string $org_id The ID of the organization that you want to add an owner for. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body The user to add as an owner of the organization. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postOrgsIDOwnersRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/OrganizationsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/OrganizationsService.php
MIT
public function deleteTelegrafsID($telegraf_id, $zap_trace_span = null) { $this->deleteTelegrafsIDWithHttpInfo($telegraf_id, $zap_trace_span); }
Operation deleteTelegrafsID Delete a Telegraf configuration @param string $telegraf_id The Telegraf configuration ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
deleteTelegrafsID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function deleteTelegrafsIDWithHttpInfo($telegraf_id, $zap_trace_span = null) { $request = $this->deleteTelegrafsIDRequest($telegraf_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation deleteTelegrafsIDWithHttpInfo Delete a Telegraf configuration @param string $telegraf_id The Telegraf configuration ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
deleteTelegrafsIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function deleteTelegrafsIDRequest($telegraf_id, $zap_trace_span = null) { // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling deleteTelegrafsID' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('DELETE', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'deleteTelegrafsID' @param string $telegraf_id The Telegraf configuration ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
deleteTelegrafsIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function deleteTelegrafsIDLabelsID($telegraf_id, $label_id, $zap_trace_span = null) { $this->deleteTelegrafsIDLabelsIDWithHttpInfo($telegraf_id, $label_id, $zap_trace_span); }
Operation deleteTelegrafsIDLabelsID Delete a label from a Telegraf config @param string $telegraf_id The Telegraf config ID. (required) @param string $label_id The label ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
deleteTelegrafsIDLabelsID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function deleteTelegrafsIDLabelsIDWithHttpInfo($telegraf_id, $label_id, $zap_trace_span = null) { $request = $this->deleteTelegrafsIDLabelsIDRequest($telegraf_id, $label_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation deleteTelegrafsIDLabelsIDWithHttpInfo Delete a label from a Telegraf config @param string $telegraf_id The Telegraf config ID. (required) @param string $label_id The label ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
deleteTelegrafsIDLabelsIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function deleteTelegrafsIDLabelsIDRequest($telegraf_id, $label_id, $zap_trace_span = null) { // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling deleteTelegrafsIDLabelsID' ); } // verify the required parameter 'label_id' is set if ($label_id === null || (is_array($label_id) && count($label_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $label_id when calling deleteTelegrafsIDLabelsID' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}/labels/{labelID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // path params if ($label_id !== null) { $resourcePath = str_replace( '{' . 'labelID' . '}', ObjectSerializer::toPathValue($label_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('DELETE', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'deleteTelegrafsIDLabelsID' @param string $telegraf_id The Telegraf config ID. (required) @param string $label_id The label ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
deleteTelegrafsIDLabelsIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function deleteTelegrafsIDMembersID($user_id, $telegraf_id, $zap_trace_span = null) { $this->deleteTelegrafsIDMembersIDWithHttpInfo($user_id, $telegraf_id, $zap_trace_span); }
Operation deleteTelegrafsIDMembersID Remove a member from a Telegraf config @param string $user_id The ID of the member to remove. (required) @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
deleteTelegrafsIDMembersID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function deleteTelegrafsIDMembersIDWithHttpInfo($user_id, $telegraf_id, $zap_trace_span = null) { $request = $this->deleteTelegrafsIDMembersIDRequest($user_id, $telegraf_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation deleteTelegrafsIDMembersIDWithHttpInfo Remove a member from a Telegraf config @param string $user_id The ID of the member to remove. (required) @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
deleteTelegrafsIDMembersIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function deleteTelegrafsIDMembersIDRequest($user_id, $telegraf_id, $zap_trace_span = null) { // verify the required parameter 'user_id' is set if ($user_id === null || (is_array($user_id) && count($user_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $user_id when calling deleteTelegrafsIDMembersID' ); } // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling deleteTelegrafsIDMembersID' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}/members/{userID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($user_id !== null) { $resourcePath = str_replace( '{' . 'userID' . '}', ObjectSerializer::toPathValue($user_id), $resourcePath ); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('DELETE', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'deleteTelegrafsIDMembersID' @param string $user_id The ID of the member to remove. (required) @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
deleteTelegrafsIDMembersIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function deleteTelegrafsIDOwnersID($user_id, $telegraf_id, $zap_trace_span = null) { $this->deleteTelegrafsIDOwnersIDWithHttpInfo($user_id, $telegraf_id, $zap_trace_span); }
Operation deleteTelegrafsIDOwnersID Remove an owner from a Telegraf config @param string $user_id The ID of the owner to remove. (required) @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
deleteTelegrafsIDOwnersID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function deleteTelegrafsIDOwnersIDWithHttpInfo($user_id, $telegraf_id, $zap_trace_span = null) { $request = $this->deleteTelegrafsIDOwnersIDRequest($user_id, $telegraf_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation deleteTelegrafsIDOwnersIDWithHttpInfo Remove an owner from a Telegraf config @param string $user_id The ID of the owner to remove. (required) @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
deleteTelegrafsIDOwnersIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function deleteTelegrafsIDOwnersIDRequest($user_id, $telegraf_id, $zap_trace_span = null) { // verify the required parameter 'user_id' is set if ($user_id === null || (is_array($user_id) && count($user_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $user_id when calling deleteTelegrafsIDOwnersID' ); } // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling deleteTelegrafsIDOwnersID' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}/owners/{userID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($user_id !== null) { $resourcePath = str_replace( '{' . 'userID' . '}', ObjectSerializer::toPathValue($user_id), $resourcePath ); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('DELETE', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'deleteTelegrafsIDOwnersID' @param string $user_id The ID of the owner to remove. (required) @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
deleteTelegrafsIDOwnersIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function getTelegrafs($zap_trace_span = null, $org_id = null) { list($response) = $this->getTelegrafsWithHttpInfo($zap_trace_span, $org_id); return $response; }
Operation getTelegrafs List all Telegraf configurations @param string $zap_trace_span OpenTracing span context (optional) @param string $org_id The organization ID the Telegraf config belongs to. (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\Telegrafs|\InfluxDB2\Model\Error
getTelegrafs
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function getTelegrafsWithHttpInfo($zap_trace_span = null, $org_id = null) { $request = $this->getTelegrafsRequest($zap_trace_span, $org_id); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\Telegrafs'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation getTelegrafsWithHttpInfo List all Telegraf configurations @param string $zap_trace_span OpenTracing span context (optional) @param string $org_id The organization ID the Telegraf config belongs to. (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\Telegrafs|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
getTelegrafsWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function getTelegrafsRequest($zap_trace_span = null, $org_id = null) { $resourcePath = '/api/v2/telegrafs'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // query params if ($org_id !== null) { $queryParams['orgID'] = ObjectSerializer::toQueryValue($org_id); } // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('GET', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'getTelegrafs' @param string $zap_trace_span OpenTracing span context (optional) @param string $org_id The organization ID the Telegraf config belongs to. (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
getTelegrafsRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function getTelegrafsID($telegraf_id, $zap_trace_span = null, $accept = 'application/toml') { list($response) = $this->getTelegrafsIDWithHttpInfo($telegraf_id, $zap_trace_span, $accept); return $response; }
Operation getTelegrafsID Retrieve a Telegraf configuration @param string $telegraf_id The Telegraf configuration ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $accept accept (optional, default to 'application/toml') @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return string|\InfluxDB2\Model\Error
getTelegrafsID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function getTelegrafsIDWithHttpInfo($telegraf_id, $zap_trace_span = null, $accept = 'application/toml') { $request = $this->getTelegrafsIDRequest($telegraf_id, $zap_trace_span, $accept); $response = $this->defaultApi->sendRequest($request); $returnType = 'string'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation getTelegrafsIDWithHttpInfo Retrieve a Telegraf configuration @param string $telegraf_id The Telegraf configuration ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $accept (optional, default to 'application/toml') @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of string|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
getTelegrafsIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function getTelegrafsIDRequest($telegraf_id, $zap_trace_span = null, $accept = 'application/toml') { // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling getTelegrafsID' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // header params if ($accept !== null) { $headerParams['Accept'] = ObjectSerializer::toHeaderValue($accept); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/toml', 'application/json', 'application/octet-stream'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/toml', 'application/json', 'application/octet-stream'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('GET', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'getTelegrafsID' @param string $telegraf_id The Telegraf configuration ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $accept (optional, default to 'application/toml') @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
getTelegrafsIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function getTelegrafsIDLabels($telegraf_id, $zap_trace_span = null) { list($response) = $this->getTelegrafsIDLabelsWithHttpInfo($telegraf_id, $zap_trace_span); return $response; }
Operation getTelegrafsIDLabels List all labels for a Telegraf config @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\LabelsResponse|\InfluxDB2\Model\Error
getTelegrafsIDLabels
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function getTelegrafsIDLabelsWithHttpInfo($telegraf_id, $zap_trace_span = null) { $request = $this->getTelegrafsIDLabelsRequest($telegraf_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\LabelsResponse'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation getTelegrafsIDLabelsWithHttpInfo List all labels for a Telegraf config @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\LabelsResponse|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
getTelegrafsIDLabelsWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function getTelegrafsIDLabelsRequest($telegraf_id, $zap_trace_span = null) { // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling getTelegrafsIDLabels' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}/labels'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('GET', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'getTelegrafsIDLabels' @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
getTelegrafsIDLabelsRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function getTelegrafsIDMembers($telegraf_id, $zap_trace_span = null) { list($response) = $this->getTelegrafsIDMembersWithHttpInfo($telegraf_id, $zap_trace_span); return $response; }
Operation getTelegrafsIDMembers List all users with member privileges for a Telegraf config @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\ResourceMembers|\InfluxDB2\Model\Error
getTelegrafsIDMembers
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function getTelegrafsIDMembersWithHttpInfo($telegraf_id, $zap_trace_span = null) { $request = $this->getTelegrafsIDMembersRequest($telegraf_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\ResourceMembers'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation getTelegrafsIDMembersWithHttpInfo List all users with member privileges for a Telegraf config @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\ResourceMembers|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
getTelegrafsIDMembersWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function getTelegrafsIDMembersRequest($telegraf_id, $zap_trace_span = null) { // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling getTelegrafsIDMembers' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}/members'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('GET', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'getTelegrafsIDMembers' @param string $telegraf_id The Telegraf config ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
getTelegrafsIDMembersRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function getTelegrafsIDOwners($telegraf_id, $zap_trace_span = null) { list($response) = $this->getTelegrafsIDOwnersWithHttpInfo($telegraf_id, $zap_trace_span); return $response; }
Operation getTelegrafsIDOwners List all owners of a Telegraf configuration @param string $telegraf_id The Telegraf configuration ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\ResourceOwners|\InfluxDB2\Model\Error
getTelegrafsIDOwners
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function getTelegrafsIDOwnersWithHttpInfo($telegraf_id, $zap_trace_span = null) { $request = $this->getTelegrafsIDOwnersRequest($telegraf_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\ResourceOwners'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation getTelegrafsIDOwnersWithHttpInfo List all owners of a Telegraf configuration @param string $telegraf_id The Telegraf configuration ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\ResourceOwners|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
getTelegrafsIDOwnersWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function getTelegrafsIDOwnersRequest($telegraf_id, $zap_trace_span = null) { // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling getTelegrafsIDOwners' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}/owners'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('GET', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'getTelegrafsIDOwners' @param string $telegraf_id The Telegraf configuration ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
getTelegrafsIDOwnersRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function postTelegrafs($telegraf_plugin_request, $zap_trace_span = null) { list($response) = $this->postTelegrafsWithHttpInfo($telegraf_plugin_request, $zap_trace_span); return $response; }
Operation postTelegrafs Create a Telegraf configuration @param \InfluxDB2\Model\TelegrafPluginRequest $telegraf_plugin_request Telegraf configuration to create (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\Telegraf|\InfluxDB2\Model\Error
postTelegrafs
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function postTelegrafsWithHttpInfo($telegraf_plugin_request, $zap_trace_span = null) { $request = $this->postTelegrafsRequest($telegraf_plugin_request, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\Telegraf'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation postTelegrafsWithHttpInfo Create a Telegraf configuration @param \InfluxDB2\Model\TelegrafPluginRequest $telegraf_plugin_request Telegraf configuration to create (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\Telegraf|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
postTelegrafsWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function postTelegrafsRequest($telegraf_plugin_request, $zap_trace_span = null) { // verify the required parameter 'telegraf_plugin_request' is set if ($telegraf_plugin_request === null || (is_array($telegraf_plugin_request) && count($telegraf_plugin_request) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_plugin_request when calling postTelegrafs' ); } $resourcePath = '/api/v2/telegrafs'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // body params $_tempBody = null; if (isset($telegraf_plugin_request)) { $_tempBody = $telegraf_plugin_request; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['application/json'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postTelegrafs' @param \InfluxDB2\Model\TelegrafPluginRequest $telegraf_plugin_request Telegraf configuration to create (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postTelegrafsRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function postTelegrafsIDLabels($telegraf_id, $label_mapping, $zap_trace_span = null) { list($response) = $this->postTelegrafsIDLabelsWithHttpInfo($telegraf_id, $label_mapping, $zap_trace_span); return $response; }
Operation postTelegrafsIDLabels Add a label to a Telegraf config @param string $telegraf_id The Telegraf config ID. (required) @param \InfluxDB2\Model\LabelMapping $label_mapping Label to add (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\LabelResponse|\InfluxDB2\Model\Error
postTelegrafsIDLabels
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function postTelegrafsIDLabelsWithHttpInfo($telegraf_id, $label_mapping, $zap_trace_span = null) { $request = $this->postTelegrafsIDLabelsRequest($telegraf_id, $label_mapping, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\LabelResponse'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation postTelegrafsIDLabelsWithHttpInfo Add a label to a Telegraf config @param string $telegraf_id The Telegraf config ID. (required) @param \InfluxDB2\Model\LabelMapping $label_mapping Label to add (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\LabelResponse|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
postTelegrafsIDLabelsWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function postTelegrafsIDLabelsRequest($telegraf_id, $label_mapping, $zap_trace_span = null) { // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling postTelegrafsIDLabels' ); } // verify the required parameter 'label_mapping' is set if ($label_mapping === null || (is_array($label_mapping) && count($label_mapping) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $label_mapping when calling postTelegrafsIDLabels' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}/labels'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if (isset($label_mapping)) { $_tempBody = $label_mapping; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['application/json'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postTelegrafsIDLabels' @param string $telegraf_id The Telegraf config ID. (required) @param \InfluxDB2\Model\LabelMapping $label_mapping Label to add (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postTelegrafsIDLabelsRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function postTelegrafsIDMembers($telegraf_id, $add_resource_member_request_body, $zap_trace_span = null) { list($response) = $this->postTelegrafsIDMembersWithHttpInfo($telegraf_id, $add_resource_member_request_body, $zap_trace_span); return $response; }
Operation postTelegrafsIDMembers Add a member to a Telegraf config @param string $telegraf_id The Telegraf config ID. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body User to add as member (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\ResourceMember|\InfluxDB2\Model\Error
postTelegrafsIDMembers
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function postTelegrafsIDMembersWithHttpInfo($telegraf_id, $add_resource_member_request_body, $zap_trace_span = null) { $request = $this->postTelegrafsIDMembersRequest($telegraf_id, $add_resource_member_request_body, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\ResourceMember'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation postTelegrafsIDMembersWithHttpInfo Add a member to a Telegraf config @param string $telegraf_id The Telegraf config ID. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body User to add as member (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\ResourceMember|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
postTelegrafsIDMembersWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function postTelegrafsIDMembersRequest($telegraf_id, $add_resource_member_request_body, $zap_trace_span = null) { // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling postTelegrafsIDMembers' ); } // verify the required parameter 'add_resource_member_request_body' is set if ($add_resource_member_request_body === null || (is_array($add_resource_member_request_body) && count($add_resource_member_request_body) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $add_resource_member_request_body when calling postTelegrafsIDMembers' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}/members'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if (isset($add_resource_member_request_body)) { $_tempBody = $add_resource_member_request_body; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['application/json'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postTelegrafsIDMembers' @param string $telegraf_id The Telegraf config ID. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body User to add as member (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postTelegrafsIDMembersRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function postTelegrafsIDOwners($telegraf_id, $add_resource_member_request_body, $zap_trace_span = null) { list($response) = $this->postTelegrafsIDOwnersWithHttpInfo($telegraf_id, $add_resource_member_request_body, $zap_trace_span); return $response; }
Operation postTelegrafsIDOwners Add an owner to a Telegraf configuration @param string $telegraf_id The Telegraf configuration ID. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body User to add as owner (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\ResourceOwner|\InfluxDB2\Model\Error
postTelegrafsIDOwners
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function postTelegrafsIDOwnersWithHttpInfo($telegraf_id, $add_resource_member_request_body, $zap_trace_span = null) { $request = $this->postTelegrafsIDOwnersRequest($telegraf_id, $add_resource_member_request_body, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\ResourceOwner'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation postTelegrafsIDOwnersWithHttpInfo Add an owner to a Telegraf configuration @param string $telegraf_id The Telegraf configuration ID. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body User to add as owner (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\ResourceOwner|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
postTelegrafsIDOwnersWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function postTelegrafsIDOwnersRequest($telegraf_id, $add_resource_member_request_body, $zap_trace_span = null) { // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling postTelegrafsIDOwners' ); } // verify the required parameter 'add_resource_member_request_body' is set if ($add_resource_member_request_body === null || (is_array($add_resource_member_request_body) && count($add_resource_member_request_body) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $add_resource_member_request_body when calling postTelegrafsIDOwners' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}/owners'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if (isset($add_resource_member_request_body)) { $_tempBody = $add_resource_member_request_body; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['application/json'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postTelegrafsIDOwners' @param string $telegraf_id The Telegraf configuration ID. (required) @param \InfluxDB2\Model\AddResourceMemberRequestBody $add_resource_member_request_body User to add as owner (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postTelegrafsIDOwnersRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function putTelegrafsID($telegraf_id, $telegraf_plugin_request, $zap_trace_span = null) { list($response) = $this->putTelegrafsIDWithHttpInfo($telegraf_id, $telegraf_plugin_request, $zap_trace_span); return $response; }
Operation putTelegrafsID Update a Telegraf configuration @param string $telegraf_id The Telegraf config ID. (required) @param \InfluxDB2\Model\TelegrafPluginRequest $telegraf_plugin_request Telegraf configuration update to apply (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\Telegraf|\InfluxDB2\Model\Error
putTelegrafsID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function putTelegrafsIDWithHttpInfo($telegraf_id, $telegraf_plugin_request, $zap_trace_span = null) { $request = $this->putTelegrafsIDRequest($telegraf_id, $telegraf_plugin_request, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\Telegraf'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation putTelegrafsIDWithHttpInfo Update a Telegraf configuration @param string $telegraf_id The Telegraf config ID. (required) @param \InfluxDB2\Model\TelegrafPluginRequest $telegraf_plugin_request Telegraf configuration update to apply (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\Telegraf|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
putTelegrafsIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
protected function putTelegrafsIDRequest($telegraf_id, $telegraf_plugin_request, $zap_trace_span = null) { // verify the required parameter 'telegraf_id' is set if ($telegraf_id === null || (is_array($telegraf_id) && count($telegraf_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_id when calling putTelegrafsID' ); } // verify the required parameter 'telegraf_plugin_request' is set if ($telegraf_plugin_request === null || (is_array($telegraf_plugin_request) && count($telegraf_plugin_request) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $telegraf_plugin_request when calling putTelegrafsID' ); } $resourcePath = '/api/v2/telegrafs/{telegrafID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($telegraf_id !== null) { $resourcePath = str_replace( '{' . 'telegrafID' . '}', ObjectSerializer::toPathValue($telegraf_id), $resourcePath ); } // body params $_tempBody = null; if (isset($telegraf_plugin_request)) { $_tempBody = $telegraf_plugin_request; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['application/json'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('PUT', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'putTelegrafsID' @param string $telegraf_id The Telegraf config ID. (required) @param \InfluxDB2\Model\TelegrafPluginRequest $telegraf_plugin_request Telegraf configuration update to apply (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
putTelegrafsIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/TelegrafsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/TelegrafsService.php
MIT
public function headPing() { $this->headPingWithHttpInfo(); }
Operation headPing Get the status of the instance @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
headPing
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/PingService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/PingService.php
MIT
public function headPingWithHttpInfo() { $request = $this->headPingRequest(); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation headPingWithHttpInfo Get the status of the instance @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
headPingWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/PingService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/PingService.php
MIT
protected function headPingRequest() { $resourcePath = '/ping'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( [] ); } else { $headers = $this->headerSelector->selectHeaders( [], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('HEAD', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'headPing' @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
headPingRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/PingService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/PingService.php
MIT
public function postWrite($org, $bucket, $body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'text/plain; charset=utf-8', $content_length = null, $accept = 'application/json', $org_id = null, $precision = null) { $this->postWriteWithHttpInfo($org, $bucket, $body, $zap_trace_span, $content_encoding, $content_type, $content_length, $accept, $org_id, $precision); }
Operation postWrite Write data @param string $org The destination organization for writes. InfluxDB writes all points in the batch to this organization. If you pass both &#x60;orgID&#x60; and &#x60;org&#x60;, they must both be valid. #### InfluxDB Cloud - Doesn&#39;t require &#x60;org&#x60; or &#x60;orgID&#x60;. - Writes to the bucket in the organization associated with the authorization (API token). #### InfluxDB OSS - Requires either &#x60;org&#x60; or &#x60;orgID&#x60;. - InfluxDB writes all points in the batch to this organization. (required) @param string $bucket The destination bucket for writes. InfluxDB writes all points in the batch to this bucket. (required) @param string $body Data in line protocol format. To send compressed data, do the following: 1. Use [GZIP](https://www.gzip.org/) to compress the line protocol data. 2. In your request, send the compressed data and the &#x60;Content-Encoding: gzip&#x60; header. #### Related guides - [Best practices for optimizing writes](https://docs.influxdata.com/influxdb/v2.3/write-data/best-practices/optimize-writes/). (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The compression applied to the line protocol in the request payload. To send a GZIP payload, pass &#x60;Content-Encoding: gzip&#x60; header. (optional, default to 'identity') @param string $content_type The format of the data in the request body. To send a line protocol payload, pass &#x60;Content-Type: text/plain; charset&#x3D;utf-8&#x60;. (optional, default to 'text/plain; charset=utf-8') @param int $content_length The size of the entity-body, in bytes, sent to InfluxDB. If the length is greater than the &#x60;max body&#x60; configuration option, the server responds with status code &#x60;413&#x60;. (optional) @param string $accept The content type that the client can understand. Writes only return a response body if they fail--for example, due to a formatting problem or quota limit. #### InfluxDB Cloud - Returns only &#x60;application/json&#x60; for format and limit errors. - Returns only &#x60;text/html&#x60; for some quota limit errors. #### InfluxDB OSS - Returns only &#x60;application/json&#x60; for format and limit errors. #### Related guides - [Troubleshoot issues writing data](https://docs.influxdata.com/influxdb/v2.3/write-data/troubleshoot/). (optional, default to 'application/json') @param string $org_id The ID of the destination organization for writes. If you pass both &#x60;orgID&#x60; and &#x60;org&#x60;, they must both be valid. #### InfluxDB Cloud - Doesn&#39;t require &#x60;org&#x60; or &#x60;orgID&#x60;. - Writes to the bucket in the organization associated with the authorization (API token). #### InfluxDB OSS - Requires either &#x60;org&#x60; or &#x60;orgID&#x60;. - InfluxDB writes all points in the batch to this organization. (optional) @param \InfluxDB2\Model\WritePrecision $precision The precision for unix timestamps in the line protocol batch. (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
postWrite
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/WriteService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/WriteService.php
MIT
public function postWriteWithHttpInfo($org, $bucket, $body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'text/plain; charset=utf-8', $content_length = null, $accept = 'application/json', $org_id = null, $precision = null) { $request = $this->postWriteRequest($org, $bucket, $body, $zap_trace_span, $content_encoding, $content_type, $content_length, $accept, $org_id, $precision); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation postWriteWithHttpInfo Write data @param string $org The destination organization for writes. InfluxDB writes all points in the batch to this organization. If you pass both &#x60;orgID&#x60; and &#x60;org&#x60;, they must both be valid. #### InfluxDB Cloud - Doesn&#39;t require &#x60;org&#x60; or &#x60;orgID&#x60;. - Writes to the bucket in the organization associated with the authorization (API token). #### InfluxDB OSS - Requires either &#x60;org&#x60; or &#x60;orgID&#x60;. - InfluxDB writes all points in the batch to this organization. (required) @param string $bucket The destination bucket for writes. InfluxDB writes all points in the batch to this bucket. (required) @param string $body Data in line protocol format. To send compressed data, do the following: 1. Use [GZIP](https://www.gzip.org/) to compress the line protocol data. 2. In your request, send the compressed data and the &#x60;Content-Encoding: gzip&#x60; header. #### Related guides - [Best practices for optimizing writes](https://docs.influxdata.com/influxdb/v2.3/write-data/best-practices/optimize-writes/). (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The compression applied to the line protocol in the request payload. To send a GZIP payload, pass &#x60;Content-Encoding: gzip&#x60; header. (optional, default to 'identity') @param string $content_type The format of the data in the request body. To send a line protocol payload, pass &#x60;Content-Type: text/plain; charset&#x3D;utf-8&#x60;. (optional, default to 'text/plain; charset=utf-8') @param int $content_length The size of the entity-body, in bytes, sent to InfluxDB. If the length is greater than the &#x60;max body&#x60; configuration option, the server responds with status code &#x60;413&#x60;. (optional) @param string $accept The content type that the client can understand. Writes only return a response body if they fail--for example, due to a formatting problem or quota limit. #### InfluxDB Cloud - Returns only &#x60;application/json&#x60; for format and limit errors. - Returns only &#x60;text/html&#x60; for some quota limit errors. #### InfluxDB OSS - Returns only &#x60;application/json&#x60; for format and limit errors. #### Related guides - [Troubleshoot issues writing data](https://docs.influxdata.com/influxdb/v2.3/write-data/troubleshoot/). (optional, default to 'application/json') @param string $org_id The ID of the destination organization for writes. If you pass both &#x60;orgID&#x60; and &#x60;org&#x60;, they must both be valid. #### InfluxDB Cloud - Doesn&#39;t require &#x60;org&#x60; or &#x60;orgID&#x60;. - Writes to the bucket in the organization associated with the authorization (API token). #### InfluxDB OSS - Requires either &#x60;org&#x60; or &#x60;orgID&#x60;. - InfluxDB writes all points in the batch to this organization. (optional) @param \InfluxDB2\Model\WritePrecision $precision The precision for unix timestamps in the line protocol batch. (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
postWriteWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/WriteService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/WriteService.php
MIT
protected function postWriteRequest($org, $bucket, $body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'text/plain; charset=utf-8', $content_length = null, $accept = 'application/json', $org_id = null, $precision = null) { // verify the required parameter 'org' is set if ($org === null || (is_array($org) && count($org) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $org when calling postWrite' ); } // verify the required parameter 'bucket' is set if ($bucket === null || (is_array($bucket) && count($bucket) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $bucket when calling postWrite' ); } // verify the required parameter 'body' is set if ($body === null || (is_array($body) && count($body) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $body when calling postWrite' ); } $resourcePath = '/api/v2/write'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // query params if ($org !== null) { $queryParams['org'] = ObjectSerializer::toQueryValue($org); } // query params if ($org_id !== null) { $queryParams['orgID'] = ObjectSerializer::toQueryValue($org_id); } // query params if ($bucket !== null) { $queryParams['bucket'] = ObjectSerializer::toQueryValue($bucket); } // query params if ($precision !== null) { $queryParams['precision'] = ObjectSerializer::toQueryValue($precision); } // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // header params if ($content_encoding !== null) { $headerParams['Content-Encoding'] = ObjectSerializer::toHeaderValue($content_encoding); } // header params if ($content_type !== null) { $headerParams['Content-Type'] = ObjectSerializer::toHeaderValue($content_type); } // header params if ($content_length !== null) { $headerParams['Content-Length'] = ObjectSerializer::toHeaderValue($content_length); } // header params if ($accept !== null) { $headerParams['Accept'] = ObjectSerializer::toHeaderValue($accept); } // body params $_tempBody = null; if (isset($body)) { $_tempBody = $body; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json', 'text/html', ] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json', 'text/html', ], ['text/plain'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postWrite' @param string $org The destination organization for writes. InfluxDB writes all points in the batch to this organization. If you pass both &#x60;orgID&#x60; and &#x60;org&#x60;, they must both be valid. #### InfluxDB Cloud - Doesn&#39;t require &#x60;org&#x60; or &#x60;orgID&#x60;. - Writes to the bucket in the organization associated with the authorization (API token). #### InfluxDB OSS - Requires either &#x60;org&#x60; or &#x60;orgID&#x60;. - InfluxDB writes all points in the batch to this organization. (required) @param string $bucket The destination bucket for writes. InfluxDB writes all points in the batch to this bucket. (required) @param string $body Data in line protocol format. To send compressed data, do the following: 1. Use [GZIP](https://www.gzip.org/) to compress the line protocol data. 2. In your request, send the compressed data and the &#x60;Content-Encoding: gzip&#x60; header. #### Related guides - [Best practices for optimizing writes](https://docs.influxdata.com/influxdb/v2.3/write-data/best-practices/optimize-writes/). (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The compression applied to the line protocol in the request payload. To send a GZIP payload, pass &#x60;Content-Encoding: gzip&#x60; header. (optional, default to 'identity') @param string $content_type The format of the data in the request body. To send a line protocol payload, pass &#x60;Content-Type: text/plain; charset&#x3D;utf-8&#x60;. (optional, default to 'text/plain; charset=utf-8') @param int $content_length The size of the entity-body, in bytes, sent to InfluxDB. If the length is greater than the &#x60;max body&#x60; configuration option, the server responds with status code &#x60;413&#x60;. (optional) @param string $accept The content type that the client can understand. Writes only return a response body if they fail--for example, due to a formatting problem or quota limit. #### InfluxDB Cloud - Returns only &#x60;application/json&#x60; for format and limit errors. - Returns only &#x60;text/html&#x60; for some quota limit errors. #### InfluxDB OSS - Returns only &#x60;application/json&#x60; for format and limit errors. #### Related guides - [Troubleshoot issues writing data](https://docs.influxdata.com/influxdb/v2.3/write-data/troubleshoot/). (optional, default to 'application/json') @param string $org_id The ID of the destination organization for writes. If you pass both &#x60;orgID&#x60; and &#x60;org&#x60;, they must both be valid. #### InfluxDB Cloud - Doesn&#39;t require &#x60;org&#x60; or &#x60;orgID&#x60;. - Writes to the bucket in the organization associated with the authorization (API token). #### InfluxDB OSS - Requires either &#x60;org&#x60; or &#x60;orgID&#x60;. - InfluxDB writes all points in the batch to this organization. (optional) @param \InfluxDB2\Model\WritePrecision $precision The precision for unix timestamps in the line protocol batch. (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postWriteRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/WriteService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/WriteService.php
MIT
public function postSignin($zap_trace_span = null, $authorization = null) { $this->postSigninWithHttpInfo($zap_trace_span, $authorization); }
Operation postSignin Create a user session. @param string $zap_trace_span OpenTracing span context (optional) @param string $authorization An auth credential for the Basic scheme (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
postSignin
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/SigninService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/SigninService.php
MIT
public function postSigninWithHttpInfo($zap_trace_span = null, $authorization = null) { $request = $this->postSigninRequest($zap_trace_span, $authorization); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation postSigninWithHttpInfo Create a user session. @param string $zap_trace_span OpenTracing span context (optional) @param string $authorization An auth credential for the Basic scheme (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
postSigninWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/SigninService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/SigninService.php
MIT
protected function postSigninRequest($zap_trace_span = null, $authorization = null) { $resourcePath = '/api/v2/signin'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // header params if ($authorization !== null) { $headerParams['Authorization'] = ObjectSerializer::toHeaderValue($authorization); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } // this endpoint requires HTTP basic authentication if ($this->config->getUsername() !== null || $this->config->getPassword() !== null) { $headers['Authorization'] = 'Basic ' . base64_encode($this->config->getUsername() . ":" . $this->config->getPassword()); } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postSignin' @param string $zap_trace_span OpenTracing span context (optional) @param string $authorization An auth credential for the Basic scheme (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postSigninRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/SigninService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/SigninService.php
MIT
public function postRestoreBucketID($bucket_id, $body, $zap_trace_span = null, $content_type = 'application/octet-stream') { list($response) = $this->postRestoreBucketIDWithHttpInfo($bucket_id, $body, $zap_trace_span, $content_type); return $response; }
Operation postRestoreBucketID Overwrite storage metadata for a bucket with shard info from a backup. @param string $bucket_id The bucket ID. (required) @param string $body Database info serialized as protobuf. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_type content_type (optional, default to 'application/octet-stream') @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return string|string
postRestoreBucketID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
public function postRestoreBucketIDWithHttpInfo($bucket_id, $body, $zap_trace_span = null, $content_type = 'application/octet-stream') { $request = $this->postRestoreBucketIDRequest($bucket_id, $body, $zap_trace_span, $content_type); $response = $this->defaultApi->sendRequest($request); $returnType = 'string'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation postRestoreBucketIDWithHttpInfo Overwrite storage metadata for a bucket with shard info from a backup. @param string $bucket_id The bucket ID. (required) @param string $body Database info serialized as protobuf. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_type (optional, default to 'application/octet-stream') @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of string|string, HTTP status code, HTTP response headers (array of strings)
postRestoreBucketIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
protected function postRestoreBucketIDRequest($bucket_id, $body, $zap_trace_span = null, $content_type = 'application/octet-stream') { // verify the required parameter 'bucket_id' is set if ($bucket_id === null || (is_array($bucket_id) && count($bucket_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $bucket_id when calling postRestoreBucketID' ); } // verify the required parameter 'body' is set if ($body === null || (is_array($body) && count($body) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $body when calling postRestoreBucketID' ); } $resourcePath = '/api/v2/restore/bucket/{bucketID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // header params if ($content_type !== null) { $headerParams['Content-Type'] = ObjectSerializer::toHeaderValue($content_type); } // path params if ($bucket_id !== null) { $resourcePath = str_replace( '{' . 'bucketID' . '}', ObjectSerializer::toPathValue($bucket_id), $resourcePath ); } // body params $_tempBody = null; if (isset($body)) { $_tempBody = $body; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['text/plain'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postRestoreBucketID' @param string $bucket_id The bucket ID. (required) @param string $body Database info serialized as protobuf. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_type (optional, default to 'application/octet-stream') @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postRestoreBucketIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
public function postRestoreBucketMetadata($bucket_metadata_manifest, $zap_trace_span = null) { list($response) = $this->postRestoreBucketMetadataWithHttpInfo($bucket_metadata_manifest, $zap_trace_span); return $response; }
Operation postRestoreBucketMetadata Create a new bucket pre-seeded with shard info from a backup. @param \InfluxDB2\Model\BucketMetadataManifest $bucket_metadata_manifest Metadata manifest for a bucket. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\RestoredBucketMappings|string
postRestoreBucketMetadata
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
public function postRestoreBucketMetadataWithHttpInfo($bucket_metadata_manifest, $zap_trace_span = null) { $request = $this->postRestoreBucketMetadataRequest($bucket_metadata_manifest, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\RestoredBucketMappings'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation postRestoreBucketMetadataWithHttpInfo Create a new bucket pre-seeded with shard info from a backup. @param \InfluxDB2\Model\BucketMetadataManifest $bucket_metadata_manifest Metadata manifest for a bucket. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\RestoredBucketMappings|string, HTTP status code, HTTP response headers (array of strings)
postRestoreBucketMetadataWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
protected function postRestoreBucketMetadataRequest($bucket_metadata_manifest, $zap_trace_span = null) { // verify the required parameter 'bucket_metadata_manifest' is set if ($bucket_metadata_manifest === null || (is_array($bucket_metadata_manifest) && count($bucket_metadata_manifest) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $bucket_metadata_manifest when calling postRestoreBucketMetadata' ); } $resourcePath = '/api/v2/restore/bucketMetadata'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // body params $_tempBody = null; if (isset($bucket_metadata_manifest)) { $_tempBody = $bucket_metadata_manifest; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['application/json'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postRestoreBucketMetadata' @param \InfluxDB2\Model\BucketMetadataManifest $bucket_metadata_manifest Metadata manifest for a bucket. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postRestoreBucketMetadataRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
public function postRestoreKV($body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'application/octet-stream') { list($response) = $this->postRestoreKVWithHttpInfo($body, $zap_trace_span, $content_encoding, $content_type); return $response; }
Operation postRestoreKV Overwrite the embedded KV store on the server with a backed-up snapshot. @param \SplFileObject $body Full KV snapshot. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The value tells InfluxDB what compression is applied to the line protocol in the request payload. To make an API request with a GZIP payload, send &#x60;Content-Encoding: gzip&#x60; as a request header. (optional, default to 'identity') @param string $content_type content_type (optional, default to 'application/octet-stream') @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\PostRestoreKVResponse|string
postRestoreKV
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
public function postRestoreKVWithHttpInfo($body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'application/octet-stream') { $request = $this->postRestoreKVRequest($body, $zap_trace_span, $content_encoding, $content_type); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\PostRestoreKVResponse'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation postRestoreKVWithHttpInfo Overwrite the embedded KV store on the server with a backed-up snapshot. @param \SplFileObject $body Full KV snapshot. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The value tells InfluxDB what compression is applied to the line protocol in the request payload. To make an API request with a GZIP payload, send &#x60;Content-Encoding: gzip&#x60; as a request header. (optional, default to 'identity') @param string $content_type (optional, default to 'application/octet-stream') @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\PostRestoreKVResponse|string, HTTP status code, HTTP response headers (array of strings)
postRestoreKVWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
protected function postRestoreKVRequest($body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'application/octet-stream') { // verify the required parameter 'body' is set if ($body === null || (is_array($body) && count($body) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $body when calling postRestoreKV' ); } $resourcePath = '/api/v2/restore/kv'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // header params if ($content_encoding !== null) { $headerParams['Content-Encoding'] = ObjectSerializer::toHeaderValue($content_encoding); } // header params if ($content_type !== null) { $headerParams['Content-Type'] = ObjectSerializer::toHeaderValue($content_type); } // body params $_tempBody = null; if (isset($body)) { $_tempBody = $body; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['text/plain'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postRestoreKV' @param \SplFileObject $body Full KV snapshot. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The value tells InfluxDB what compression is applied to the line protocol in the request payload. To make an API request with a GZIP payload, send &#x60;Content-Encoding: gzip&#x60; as a request header. (optional, default to 'identity') @param string $content_type (optional, default to 'application/octet-stream') @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postRestoreKVRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
public function postRestoreSQL($body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'application/octet-stream') { $this->postRestoreSQLWithHttpInfo($body, $zap_trace_span, $content_encoding, $content_type); }
Operation postRestoreSQL Overwrite the embedded SQL store on the server with a backed-up snapshot. @param \SplFileObject $body Full SQL snapshot. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The value tells InfluxDB what compression is applied to the line protocol in the request payload. To make an API request with a GZIP payload, send &#x60;Content-Encoding: gzip&#x60; as a request header. (optional, default to 'identity') @param string $content_type content_type (optional, default to 'application/octet-stream') @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
postRestoreSQL
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
public function postRestoreSQLWithHttpInfo($body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'application/octet-stream') { $request = $this->postRestoreSQLRequest($body, $zap_trace_span, $content_encoding, $content_type); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation postRestoreSQLWithHttpInfo Overwrite the embedded SQL store on the server with a backed-up snapshot. @param \SplFileObject $body Full SQL snapshot. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The value tells InfluxDB what compression is applied to the line protocol in the request payload. To make an API request with a GZIP payload, send &#x60;Content-Encoding: gzip&#x60; as a request header. (optional, default to 'identity') @param string $content_type (optional, default to 'application/octet-stream') @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
postRestoreSQLWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
protected function postRestoreSQLRequest($body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'application/octet-stream') { // verify the required parameter 'body' is set if ($body === null || (is_array($body) && count($body) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $body when calling postRestoreSQL' ); } $resourcePath = '/api/v2/restore/sql'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // header params if ($content_encoding !== null) { $headerParams['Content-Encoding'] = ObjectSerializer::toHeaderValue($content_encoding); } // header params if ($content_type !== null) { $headerParams['Content-Type'] = ObjectSerializer::toHeaderValue($content_type); } // body params $_tempBody = null; if (isset($body)) { $_tempBody = $body; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['text/plain'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postRestoreSQL' @param \SplFileObject $body Full SQL snapshot. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The value tells InfluxDB what compression is applied to the line protocol in the request payload. To make an API request with a GZIP payload, send &#x60;Content-Encoding: gzip&#x60; as a request header. (optional, default to 'identity') @param string $content_type (optional, default to 'application/octet-stream') @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postRestoreSQLRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
public function postRestoreShardId($shard_id, $body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'application/octet-stream') { $this->postRestoreShardIdWithHttpInfo($shard_id, $body, $zap_trace_span, $content_encoding, $content_type); }
Operation postRestoreShardId Restore a TSM snapshot into a shard. @param string $shard_id The shard ID. (required) @param \SplFileObject $body TSM snapshot. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The value tells InfluxDB what compression is applied to the line protocol in the request payload. To make an API request with a GZIP payload, send &#x60;Content-Encoding: gzip&#x60; as a request header. (optional, default to 'identity') @param string $content_type content_type (optional, default to 'application/octet-stream') @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
postRestoreShardId
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
public function postRestoreShardIdWithHttpInfo($shard_id, $body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'application/octet-stream') { $request = $this->postRestoreShardIdRequest($shard_id, $body, $zap_trace_span, $content_encoding, $content_type); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation postRestoreShardIdWithHttpInfo Restore a TSM snapshot into a shard. @param string $shard_id The shard ID. (required) @param \SplFileObject $body TSM snapshot. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The value tells InfluxDB what compression is applied to the line protocol in the request payload. To make an API request with a GZIP payload, send &#x60;Content-Encoding: gzip&#x60; as a request header. (optional, default to 'identity') @param string $content_type (optional, default to 'application/octet-stream') @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
postRestoreShardIdWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
protected function postRestoreShardIdRequest($shard_id, $body, $zap_trace_span = null, $content_encoding = 'identity', $content_type = 'application/octet-stream') { // verify the required parameter 'shard_id' is set if ($shard_id === null || (is_array($shard_id) && count($shard_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $shard_id when calling postRestoreShardId' ); } // verify the required parameter 'body' is set if ($body === null || (is_array($body) && count($body) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $body when calling postRestoreShardId' ); } $resourcePath = '/api/v2/restore/shards/{shardID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // header params if ($content_encoding !== null) { $headerParams['Content-Encoding'] = ObjectSerializer::toHeaderValue($content_encoding); } // header params if ($content_type !== null) { $headerParams['Content-Type'] = ObjectSerializer::toHeaderValue($content_type); } // path params if ($shard_id !== null) { $resourcePath = str_replace( '{' . 'shardID' . '}', ObjectSerializer::toPathValue($shard_id), $resourcePath ); } // body params $_tempBody = null; if (isset($body)) { $_tempBody = $body; } if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], ['text/plain'] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('POST', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'postRestoreShardId' @param string $shard_id The shard ID. (required) @param \SplFileObject $body TSM snapshot. (required) @param string $zap_trace_span OpenTracing span context (optional) @param string $content_encoding The value tells InfluxDB what compression is applied to the line protocol in the request payload. To make an API request with a GZIP payload, send &#x60;Content-Encoding: gzip&#x60; as a request header. (optional, default to 'identity') @param string $content_type (optional, default to 'application/octet-stream') @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
postRestoreShardIdRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RestoreService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RestoreService.php
MIT
public function getNotificationRulesIDQuery($rule_id, $zap_trace_span = null) { list($response) = $this->getNotificationRulesIDQueryWithHttpInfo($rule_id, $zap_trace_span); return $response; }
Operation getNotificationRulesIDQuery Retrieve a notification rule query @param string $rule_id The notification rule ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return \InfluxDB2\Model\FluxResponse|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error
getNotificationRulesIDQuery
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RulesService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RulesService.php
MIT
public function getNotificationRulesIDQueryWithHttpInfo($rule_id, $zap_trace_span = null) { $request = $this->getNotificationRulesIDQueryRequest($rule_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); $returnType = '\InfluxDB2\Model\FluxResponse'; $responseBody = $response->getBody(); if ($returnType === '\SplFileObject') { $content = $responseBody; //stream goes to serializer } else { $content = $responseBody->getContents(); } return [ ObjectSerializer::deserialize($content, $returnType, []), $response->getStatusCode(), $response->getHeaders() ]; }
Operation getNotificationRulesIDQueryWithHttpInfo Retrieve a notification rule query @param string $rule_id The notification rule ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of \InfluxDB2\Model\FluxResponse|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error|\InfluxDB2\Model\Error, HTTP status code, HTTP response headers (array of strings)
getNotificationRulesIDQueryWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RulesService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RulesService.php
MIT
protected function getNotificationRulesIDQueryRequest($rule_id, $zap_trace_span = null) { // verify the required parameter 'rule_id' is set if ($rule_id === null || (is_array($rule_id) && count($rule_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $rule_id when calling getNotificationRulesIDQuery' ); } $resourcePath = '/api/v2/notificationRules/{ruleID}/query'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($rule_id !== null) { $resourcePath = str_replace( '{' . 'ruleID' . '}', ObjectSerializer::toPathValue($rule_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('GET', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'getNotificationRulesIDQuery' @param string $rule_id The notification rule ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
getNotificationRulesIDQueryRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/RulesService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/RulesService.php
MIT
public function deleteScrapersID($scraper_target_id, $zap_trace_span = null) { $this->deleteScrapersIDWithHttpInfo($scraper_target_id, $zap_trace_span); }
Operation deleteScrapersID Delete a scraper target @param string $scraper_target_id The identifier of the scraper target. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
deleteScrapersID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/ScraperTargetsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/ScraperTargetsService.php
MIT
public function deleteScrapersIDWithHttpInfo($scraper_target_id, $zap_trace_span = null) { $request = $this->deleteScrapersIDRequest($scraper_target_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation deleteScrapersIDWithHttpInfo Delete a scraper target @param string $scraper_target_id The identifier of the scraper target. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
deleteScrapersIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/ScraperTargetsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/ScraperTargetsService.php
MIT
protected function deleteScrapersIDRequest($scraper_target_id, $zap_trace_span = null) { // verify the required parameter 'scraper_target_id' is set if ($scraper_target_id === null || (is_array($scraper_target_id) && count($scraper_target_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $scraper_target_id when calling deleteScrapersID' ); } $resourcePath = '/api/v2/scrapers/{scraperTargetID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($scraper_target_id !== null) { $resourcePath = str_replace( '{' . 'scraperTargetID' . '}', ObjectSerializer::toPathValue($scraper_target_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('DELETE', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'deleteScrapersID' @param string $scraper_target_id The identifier of the scraper target. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
deleteScrapersIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/ScraperTargetsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/ScraperTargetsService.php
MIT
public function deleteScrapersIDLabelsID($scraper_target_id, $label_id, $zap_trace_span = null) { $this->deleteScrapersIDLabelsIDWithHttpInfo($scraper_target_id, $label_id, $zap_trace_span); }
Operation deleteScrapersIDLabelsID Delete a label from a scraper target @param string $scraper_target_id The scraper target ID. (required) @param string $label_id The label ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
deleteScrapersIDLabelsID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/ScraperTargetsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/ScraperTargetsService.php
MIT
public function deleteScrapersIDLabelsIDWithHttpInfo($scraper_target_id, $label_id, $zap_trace_span = null) { $request = $this->deleteScrapersIDLabelsIDRequest($scraper_target_id, $label_id, $zap_trace_span); $response = $this->defaultApi->sendRequest($request); return [null, $response->getStatusCode(), $response->getHeaders()]; }
Operation deleteScrapersIDLabelsIDWithHttpInfo Delete a label from a scraper target @param string $scraper_target_id The scraper target ID. (required) @param string $label_id The label ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return array of null, HTTP status code, HTTP response headers (array of strings)
deleteScrapersIDLabelsIDWithHttpInfo
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/ScraperTargetsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/ScraperTargetsService.php
MIT
protected function deleteScrapersIDLabelsIDRequest($scraper_target_id, $label_id, $zap_trace_span = null) { // verify the required parameter 'scraper_target_id' is set if ($scraper_target_id === null || (is_array($scraper_target_id) && count($scraper_target_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $scraper_target_id when calling deleteScrapersIDLabelsID' ); } // verify the required parameter 'label_id' is set if ($label_id === null || (is_array($label_id) && count($label_id) === 0)) { throw new \InvalidArgumentException( 'Missing the required parameter $label_id when calling deleteScrapersIDLabelsID' ); } $resourcePath = '/api/v2/scrapers/{scraperTargetID}/labels/{labelID}'; $queryParams = []; $headerParams = []; $httpBody = ''; $multipart = false; // header params if ($zap_trace_span !== null) { $headerParams['Zap-Trace-Span'] = ObjectSerializer::toHeaderValue($zap_trace_span); } // path params if ($scraper_target_id !== null) { $resourcePath = str_replace( '{' . 'scraperTargetID' . '}', ObjectSerializer::toPathValue($scraper_target_id), $resourcePath ); } // path params if ($label_id !== null) { $resourcePath = str_replace( '{' . 'labelID' . '}', ObjectSerializer::toPathValue($label_id), $resourcePath ); } // body params $_tempBody = null; if ($multipart) { $headers = $this->headerSelector->selectHeadersForMultipart( ['application/json'] ); } else { $headers = $this->headerSelector->selectHeaders( ['application/json'], [] ); } // for model (json/xml) if (isset($_tempBody)) { // $_tempBody is the method argument, if present if ($headers['Content-Type'] === 'application/json') { $httpBody = json_encode(ObjectSerializer::sanitizeForSerialization($_tempBody)); } else { $httpBody = $_tempBody; } } $headers = array_merge( $headerParams, $headers ); return $this->defaultApi->createRequest('DELETE', $resourcePath, $httpBody, $headers, $queryParams); }
Create request for operation 'deleteScrapersIDLabelsID' @param string $scraper_target_id The scraper target ID. (required) @param string $label_id The label ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InvalidArgumentException @return \Psr\Http\Message\RequestInterface
deleteScrapersIDLabelsIDRequest
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/ScraperTargetsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/ScraperTargetsService.php
MIT
public function deleteScrapersIDMembersID($user_id, $scraper_target_id, $zap_trace_span = null) { $this->deleteScrapersIDMembersIDWithHttpInfo($user_id, $scraper_target_id, $zap_trace_span); }
Operation deleteScrapersIDMembersID Remove a member from a scraper target @param string $user_id The ID of member to remove. (required) @param string $scraper_target_id The scraper target ID. (required) @param string $zap_trace_span OpenTracing span context (optional) @throws \InfluxDB2\ApiException on non-2xx response @throws \InvalidArgumentException @return void
deleteScrapersIDMembersID
php
influxdata/influxdb-client-php
src/InfluxDB2/Service/ScraperTargetsService.php
https://github.com/influxdata/influxdb-client-php/blob/master/src/InfluxDB2/Service/ScraperTargetsService.php
MIT