Tectly PHP Client

DocumentsApi
in package

DocumentsApi Class Doc Comment

Tags
category

Class

author

OpenAPI Generator team

link
https://openapi-generator.tech

Table of Contents

Constants

contentTypes  = ['addDocument' => ['multipart/form-data'], 'fetchDocument' => ['application/json'], 'fetchDocuments' => ['application/json'], 'removeDocument' => ['application/json']]

Properties

$client  : ClientInterface
$config  : Configuration
$headerSelector  : HeaderSelector
$hostIndex  : int

Methods

__construct()  : mixed
addDocument()  : mixed
Operation addDocument
addDocumentAsync()  : PromiseInterface
Operation addDocumentAsync
addDocumentAsyncWithHttpInfo()  : PromiseInterface
Operation addDocumentAsyncWithHttpInfo
addDocumentRequest()  : Request
Create request for operation 'addDocument'
addDocumentWithHttpInfo()  : array<string|int, mixed>
Operation addDocumentWithHttpInfo
fetchDocument()  : Document
Operation fetchDocument
fetchDocumentAsync()  : PromiseInterface
Operation fetchDocumentAsync
fetchDocumentAsyncWithHttpInfo()  : PromiseInterface
Operation fetchDocumentAsyncWithHttpInfo
fetchDocumentRequest()  : Request
Create request for operation 'fetchDocument'
fetchDocuments()  : DocumentsPage
Operation fetchDocuments
fetchDocumentsAsync()  : PromiseInterface
Operation fetchDocumentsAsync
fetchDocumentsAsyncWithHttpInfo()  : PromiseInterface
Operation fetchDocumentsAsyncWithHttpInfo
fetchDocumentsRequest()  : Request
Create request for operation 'fetchDocuments'
fetchDocumentsWithHttpInfo()  : array<string|int, mixed>
Operation fetchDocumentsWithHttpInfo
fetchDocumentWithHttpInfo()  : array<string|int, mixed>
Operation fetchDocumentWithHttpInfo
getConfig()  : Configuration
getHostIndex()  : int
Get the host index
removeDocument()  : void
Operation removeDocument
removeDocumentAsync()  : PromiseInterface
Operation removeDocumentAsync
removeDocumentAsyncWithHttpInfo()  : PromiseInterface
Operation removeDocumentAsyncWithHttpInfo
removeDocumentRequest()  : Request
Create request for operation 'removeDocument'
removeDocumentWithHttpInfo()  : array<string|int, mixed>
Operation removeDocumentWithHttpInfo
setHostIndex()  : void
Set the host index
createHttpClientOption()  : array<string|int, mixed>
Create http client option
handleResponseWithDataType()  : array<string|int, mixed>
responseWithinRangeCode()  : bool

Constants

contentTypes

public array<string|int, string> contentTypes = ['addDocument' => ['multipart/form-data'], 'fetchDocument' => ['application/json'], 'fetchDocuments' => ['application/json'], 'removeDocument' => ['application/json']]

Properties

Methods

__construct()

public __construct([ClientInterface $client = null ][, Configuration $config = null ][, HeaderSelector $selector = null ][, int $hostIndex = 0 ]) : mixed
Parameters
$client : ClientInterface = null
$config : Configuration = null
$selector : HeaderSelector = null
$hostIndex : int = 0

(Optional) host index to select the list of hosts if defined in the OpenAPI spec

addDocument()

Operation addDocument

public addDocument(string $id, SplFileObject $document[, string $contentType = self::contentTypes['addDocument'][0] ]) : mixed

Submit new document for processing.

Parameters
$id : string

id (required)

$document : SplFileObject

document (required)

$contentType : string = self::contentTypes['addDocument'][0]

The value for the Content-Type header. Check self::contentTypes['addDocument'] to see the possible values for this operation

Tags
throws
ApiException

on non-2xx response or if the response body is not in the expected format

throws
InvalidArgumentException
@return

|\Tectly\OpenAPI\Model\DocumentSummary

addDocumentAsync()

Operation addDocumentAsync

public addDocumentAsync(string $id, SplFileObject $document[, string $contentType = self::contentTypes['addDocument'][0] ]) : PromiseInterface

Submit new document for processing.

Parameters
$id : string

(required)

$document : SplFileObject

(required)

$contentType : string = self::contentTypes['addDocument'][0]

The value for the Content-Type header. Check self::contentTypes['addDocument'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
PromiseInterface

addDocumentAsyncWithHttpInfo()

Operation addDocumentAsyncWithHttpInfo

public addDocumentAsyncWithHttpInfo(string $id, SplFileObject $document[, string $contentType = self::contentTypes['addDocument'][0] ]) : PromiseInterface

Submit new document for processing.

Parameters
$id : string

(required)

$document : SplFileObject

(required)

$contentType : string = self::contentTypes['addDocument'][0]

The value for the Content-Type header. Check self::contentTypes['addDocument'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
PromiseInterface

addDocumentRequest()

Create request for operation 'addDocument'

public addDocumentRequest(string $id, SplFileObject $document[, string $contentType = self::contentTypes['addDocument'][0] ]) : Request
Parameters
$id : string

(required)

$document : SplFileObject

(required)

$contentType : string = self::contentTypes['addDocument'][0]

The value for the Content-Type header. Check self::contentTypes['addDocument'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
Request

addDocumentWithHttpInfo()

Operation addDocumentWithHttpInfo

public addDocumentWithHttpInfo(string $id, SplFileObject $document[, string $contentType = self::contentTypes['addDocument'][0] ]) : array<string|int, mixed>

Submit new document for processing.

Parameters
$id : string

(required)

$document : SplFileObject

(required)

$contentType : string = self::contentTypes['addDocument'][0]

The value for the Content-Type header. Check self::contentTypes['addDocument'] to see the possible values for this operation

Tags
throws
ApiException

on non-2xx response or if the response body is not in the expected format

throws
InvalidArgumentException
Return values
array<string|int, mixed>

of |\Tectly\OpenAPI\Model\DocumentSummary, HTTP status code, HTTP response headers (array of strings)

fetchDocument()

Operation fetchDocument

public fetchDocument(string $id[, string $contentType = self::contentTypes['fetchDocument'][0] ]) : Document

Get a document by its id.

Parameters
$id : string

id (required)

$contentType : string = self::contentTypes['fetchDocument'][0]

The value for the Content-Type header. Check self::contentTypes['fetchDocument'] to see the possible values for this operation

Tags
throws
ApiException

on non-2xx response or if the response body is not in the expected format

throws
InvalidArgumentException
Return values
Document

fetchDocumentAsync()

Operation fetchDocumentAsync

public fetchDocumentAsync(string $id[, string $contentType = self::contentTypes['fetchDocument'][0] ]) : PromiseInterface

Get a document by its id.

Parameters
$id : string

(required)

$contentType : string = self::contentTypes['fetchDocument'][0]

The value for the Content-Type header. Check self::contentTypes['fetchDocument'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
PromiseInterface

fetchDocumentAsyncWithHttpInfo()

Operation fetchDocumentAsyncWithHttpInfo

public fetchDocumentAsyncWithHttpInfo(string $id[, string $contentType = self::contentTypes['fetchDocument'][0] ]) : PromiseInterface

Get a document by its id.

Parameters
$id : string

(required)

$contentType : string = self::contentTypes['fetchDocument'][0]

The value for the Content-Type header. Check self::contentTypes['fetchDocument'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
PromiseInterface

fetchDocumentRequest()

Create request for operation 'fetchDocument'

public fetchDocumentRequest(string $id[, string $contentType = self::contentTypes['fetchDocument'][0] ]) : Request
Parameters
$id : string

(required)

$contentType : string = self::contentTypes['fetchDocument'][0]

The value for the Content-Type header. Check self::contentTypes['fetchDocument'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
Request

fetchDocuments()

Operation fetchDocuments

public fetchDocuments(string $id, Pageable $pageable[, string $contentType = self::contentTypes['fetchDocuments'][0] ]) : DocumentsPage

Get all documents paged

Parameters
$id : string

id (required)

$pageable : Pageable

pageable (required)

$contentType : string = self::contentTypes['fetchDocuments'][0]

The value for the Content-Type header. Check self::contentTypes['fetchDocuments'] to see the possible values for this operation

Tags
throws
ApiException

on non-2xx response or if the response body is not in the expected format

throws
InvalidArgumentException
Return values
DocumentsPage

fetchDocumentsAsync()

Operation fetchDocumentsAsync

public fetchDocumentsAsync(string $id, Pageable $pageable[, string $contentType = self::contentTypes['fetchDocuments'][0] ]) : PromiseInterface

Get all documents paged

Parameters
$id : string

(required)

$pageable : Pageable

(required)

$contentType : string = self::contentTypes['fetchDocuments'][0]

The value for the Content-Type header. Check self::contentTypes['fetchDocuments'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
PromiseInterface

fetchDocumentsAsyncWithHttpInfo()

Operation fetchDocumentsAsyncWithHttpInfo

public fetchDocumentsAsyncWithHttpInfo(string $id, Pageable $pageable[, string $contentType = self::contentTypes['fetchDocuments'][0] ]) : PromiseInterface

Get all documents paged

Parameters
$id : string

(required)

$pageable : Pageable

(required)

$contentType : string = self::contentTypes['fetchDocuments'][0]

The value for the Content-Type header. Check self::contentTypes['fetchDocuments'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
PromiseInterface

fetchDocumentsRequest()

Create request for operation 'fetchDocuments'

public fetchDocumentsRequest(string $id, Pageable $pageable[, string $contentType = self::contentTypes['fetchDocuments'][0] ]) : Request
Parameters
$id : string

(required)

$pageable : Pageable

(required)

$contentType : string = self::contentTypes['fetchDocuments'][0]

The value for the Content-Type header. Check self::contentTypes['fetchDocuments'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
Request

fetchDocumentsWithHttpInfo()

Operation fetchDocumentsWithHttpInfo

public fetchDocumentsWithHttpInfo(string $id, Pageable $pageable[, string $contentType = self::contentTypes['fetchDocuments'][0] ]) : array<string|int, mixed>

Get all documents paged

Parameters
$id : string

(required)

$pageable : Pageable

(required)

$contentType : string = self::contentTypes['fetchDocuments'][0]

The value for the Content-Type header. Check self::contentTypes['fetchDocuments'] to see the possible values for this operation

Tags
throws
ApiException

on non-2xx response or if the response body is not in the expected format

throws
InvalidArgumentException
Return values
array<string|int, mixed>

of \Tectly\OpenAPI\Model\DocumentsPage, HTTP status code, HTTP response headers (array of strings)

fetchDocumentWithHttpInfo()

Operation fetchDocumentWithHttpInfo

public fetchDocumentWithHttpInfo(string $id[, string $contentType = self::contentTypes['fetchDocument'][0] ]) : array<string|int, mixed>

Get a document by its id.

Parameters
$id : string

(required)

$contentType : string = self::contentTypes['fetchDocument'][0]

The value for the Content-Type header. Check self::contentTypes['fetchDocument'] to see the possible values for this operation

Tags
throws
ApiException

on non-2xx response or if the response body is not in the expected format

throws
InvalidArgumentException
Return values
array<string|int, mixed>

of \Tectly\OpenAPI\Model\Document, HTTP status code, HTTP response headers (array of strings)

getHostIndex()

Get the host index

public getHostIndex() : int
Return values
int

Host index

removeDocument()

Operation removeDocument

public removeDocument(string $id[, string $contentType = self::contentTypes['removeDocument'][0] ]) : void

Delete a document by its id.

Parameters
$id : string

id (required)

$contentType : string = self::contentTypes['removeDocument'][0]

The value for the Content-Type header. Check self::contentTypes['removeDocument'] to see the possible values for this operation

Tags
throws
ApiException

on non-2xx response or if the response body is not in the expected format

throws
InvalidArgumentException

removeDocumentAsync()

Operation removeDocumentAsync

public removeDocumentAsync(string $id[, string $contentType = self::contentTypes['removeDocument'][0] ]) : PromiseInterface

Delete a document by its id.

Parameters
$id : string

(required)

$contentType : string = self::contentTypes['removeDocument'][0]

The value for the Content-Type header. Check self::contentTypes['removeDocument'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
PromiseInterface

removeDocumentAsyncWithHttpInfo()

Operation removeDocumentAsyncWithHttpInfo

public removeDocumentAsyncWithHttpInfo(string $id[, string $contentType = self::contentTypes['removeDocument'][0] ]) : PromiseInterface

Delete a document by its id.

Parameters
$id : string

(required)

$contentType : string = self::contentTypes['removeDocument'][0]

The value for the Content-Type header. Check self::contentTypes['removeDocument'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
PromiseInterface

removeDocumentRequest()

Create request for operation 'removeDocument'

public removeDocumentRequest(string $id[, string $contentType = self::contentTypes['removeDocument'][0] ]) : Request
Parameters
$id : string

(required)

$contentType : string = self::contentTypes['removeDocument'][0]

The value for the Content-Type header. Check self::contentTypes['removeDocument'] to see the possible values for this operation

Tags
throws
InvalidArgumentException
Return values
Request

removeDocumentWithHttpInfo()

Operation removeDocumentWithHttpInfo

public removeDocumentWithHttpInfo(string $id[, string $contentType = self::contentTypes['removeDocument'][0] ]) : array<string|int, mixed>

Delete a document by its id.

Parameters
$id : string

(required)

$contentType : string = self::contentTypes['removeDocument'][0]

The value for the Content-Type header. Check self::contentTypes['removeDocument'] to see the possible values for this operation

Tags
throws
ApiException

on non-2xx response or if the response body is not in the expected format

throws
InvalidArgumentException
Return values
array<string|int, mixed>

of null, HTTP status code, HTTP response headers (array of strings)

setHostIndex()

Set the host index

public setHostIndex(int $hostIndex) : void
Parameters
$hostIndex : int

Host index (required)

createHttpClientOption()

Create http client option

protected createHttpClientOption() : array<string|int, mixed>
Tags
throws
RuntimeException

on file opening failure

Return values
array<string|int, mixed>

of http client options

handleResponseWithDataType()

private handleResponseWithDataType(string $dataType, RequestInterface $request, ResponseInterface $response) : array<string|int, mixed>
Parameters
$dataType : string
$request : RequestInterface
$response : ResponseInterface
Return values
array<string|int, mixed>

responseWithinRangeCode()

private responseWithinRangeCode(string $rangeCode, int $statusCode) : bool
Parameters
$rangeCode : string
$statusCode : int
Return values
bool

        
On this page

Search results