JobClient class

Class representing a JobClient.

Constructors

JobClient(IotHubGatewayServiceAPIsContext)

Create a JobClient.

Methods

cancelImportExportJob(string, msRest.RequestOptionsBase)

Cancels an import or export job in an IoT hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities for more information.

cancelImportExportJob(string, RequestOptionsBase, ServiceCallback<any>)
cancelImportExportJob(string, ServiceCallback<any>)
cancelJob(string, msRest.RequestOptionsBase)

Cancels a scheduled job on an IoT hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-jobs for more information.

cancelJob(string, RequestOptionsBase, ServiceCallback<JobResponse>)
cancelJob(string, ServiceCallback<JobResponse>)
createImportExportJob(JobProperties, msRest.RequestOptionsBase)

Create a new import/export job on an IoT hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities for more information.

createImportExportJob(JobProperties, RequestOptionsBase, ServiceCallback<JobProperties>)
createImportExportJob(JobProperties, ServiceCallback<JobProperties>)
createJob(string, JobRequest, msRest.RequestOptionsBase)

Creates a new job to schedule update twins or device direct methods on an IoT hub at a scheduled time. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-jobs for more information.

createJob(string, JobRequest, RequestOptionsBase, ServiceCallback<JobResponse>)
createJob(string, JobRequest, ServiceCallback<JobResponse>)
getImportExportJob(string, msRest.RequestOptionsBase)

Gets the status of an import or export job in an iot hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities for more information.

getImportExportJob(string, RequestOptionsBase, ServiceCallback<JobProperties>)
getImportExportJob(string, ServiceCallback<JobProperties>)
getImportExportJobs(msRest.RequestOptionsBase)

Gets the status of all import/export jobs in an iot hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities for more information.

getImportExportJobs(RequestOptionsBase, ServiceCallback<JobProperties[]>)
getImportExportJobs(ServiceCallback<JobProperties[]>)
getJob(string, msRest.RequestOptionsBase)

Retrieves details of a scheduled job from an IoT hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-jobs for more information.

getJob(string, RequestOptionsBase, ServiceCallback<JobResponse>)
getJob(string, ServiceCallback<JobResponse>)
queryJobs(JobClientQueryJobsOptionalParams, ServiceCallback<QueryResult>)
queryJobs(Models.JobClientQueryJobsOptionalParams)

Query an IoT hub to retrieve information regarding jobs using the IoT Hub query language. See https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-query-language for more information. Pagination of results is supported. This returns information about jobs only.

queryJobs(ServiceCallback<QueryResult>)

Constructor Details

JobClient(IotHubGatewayServiceAPIsContext)

Create a JobClient.

new JobClient(client: IotHubGatewayServiceAPIsContext)

Parameters

client
IotHubGatewayServiceAPIsContext

Reference to the service client.

Method Details

cancelImportExportJob(string, msRest.RequestOptionsBase)

Cancels an import or export job in an IoT hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities for more information.

function cancelImportExportJob(id: string, options?: msRest.RequestOptionsBase): Promise<Models.JobClientCancelImportExportJobResponse>

Parameters

id

string

Job ID.

options
msRest.RequestOptionsBase

Returns

Promise<Models.JobClientCancelImportExportJobResponse>

Promise<Models.JobClientCancelImportExportJobResponse>

cancelImportExportJob(string, RequestOptionsBase, ServiceCallback<any>)

function cancelImportExportJob(id: string, options: RequestOptionsBase, callback: ServiceCallback<any>)

Parameters

id

string

Job ID.

options

RequestOptionsBase

The optional parameters

callback

ServiceCallback<any>

The callback

cancelImportExportJob(string, ServiceCallback<any>)

function cancelImportExportJob(id: string, callback: ServiceCallback<any>)

Parameters

id

string

Job ID.

callback

ServiceCallback<any>

The callback

cancelJob(string, msRest.RequestOptionsBase)

Cancels a scheduled job on an IoT hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-jobs for more information.

function cancelJob(id: string, options?: msRest.RequestOptionsBase): Promise<Models.JobClientCancelJobResponse>

Parameters

id

string

Job ID.

options
msRest.RequestOptionsBase

Returns

Promise<Models.JobClientCancelJobResponse>

Promise<Models.JobClientCancelJobResponse>

cancelJob(string, RequestOptionsBase, ServiceCallback<JobResponse>)

function cancelJob(id: string, options: RequestOptionsBase, callback: ServiceCallback<JobResponse>)

Parameters

id

string

Job ID.

options

RequestOptionsBase

The optional parameters

callback

ServiceCallback<JobResponse>

The callback

cancelJob(string, ServiceCallback<JobResponse>)

function cancelJob(id: string, callback: ServiceCallback<JobResponse>)

Parameters

id

string

Job ID.

callback

ServiceCallback<JobResponse>

The callback

createImportExportJob(JobProperties, msRest.RequestOptionsBase)

Create a new import/export job on an IoT hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities for more information.

function createImportExportJob(jobProperties: JobProperties, options?: msRest.RequestOptionsBase): Promise<Models.JobClientCreateImportExportJobResponse>

Parameters

jobProperties
JobProperties

Specifies the job specification.

options
msRest.RequestOptionsBase

Returns

Promise<Models.JobClientCreateImportExportJobResponse>

Promise<Models.JobClientCreateImportExportJobResponse>

createImportExportJob(JobProperties, RequestOptionsBase, ServiceCallback<JobProperties>)

function createImportExportJob(jobProperties: JobProperties, options: RequestOptionsBase, callback: ServiceCallback<JobProperties>)

Parameters

jobProperties
JobProperties

Specifies the job specification.

options

RequestOptionsBase

The optional parameters

callback

ServiceCallback<JobProperties>

The callback

createImportExportJob(JobProperties, ServiceCallback<JobProperties>)

function createImportExportJob(jobProperties: JobProperties, callback: ServiceCallback<JobProperties>)

Parameters

jobProperties
JobProperties

Specifies the job specification.

callback

ServiceCallback<JobProperties>

The callback

createJob(string, JobRequest, msRest.RequestOptionsBase)

Creates a new job to schedule update twins or device direct methods on an IoT hub at a scheduled time. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-jobs for more information.

function createJob(id: string, jobRequest: JobRequest, options?: msRest.RequestOptionsBase): Promise<Models.JobClientCreateJobResponse>

Parameters

id

string

Job ID.

jobRequest
JobRequest
options
msRest.RequestOptionsBase

Returns

Promise<Models.JobClientCreateJobResponse>

Promise<Models.JobClientCreateJobResponse>

createJob(string, JobRequest, RequestOptionsBase, ServiceCallback<JobResponse>)

function createJob(id: string, jobRequest: JobRequest, options: RequestOptionsBase, callback: ServiceCallback<JobResponse>)

Parameters

id

string

Job ID.

jobRequest
JobRequest
options

RequestOptionsBase

The optional parameters

callback

ServiceCallback<JobResponse>

The callback

createJob(string, JobRequest, ServiceCallback<JobResponse>)

function createJob(id: string, jobRequest: JobRequest, callback: ServiceCallback<JobResponse>)

Parameters

id

string

Job ID.

jobRequest
JobRequest
callback

ServiceCallback<JobResponse>

The callback

getImportExportJob(string, msRest.RequestOptionsBase)

Gets the status of an import or export job in an iot hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities for more information.

function getImportExportJob(id: string, options?: msRest.RequestOptionsBase): Promise<Models.JobClientGetImportExportJobResponse>

Parameters

id

string

Job ID.

options
msRest.RequestOptionsBase

Returns

Promise<Models.JobClientGetImportExportJobResponse>

Promise<Models.JobClientGetImportExportJobResponse>

getImportExportJob(string, RequestOptionsBase, ServiceCallback<JobProperties>)

function getImportExportJob(id: string, options: RequestOptionsBase, callback: ServiceCallback<JobProperties>)

Parameters

id

string

Job ID.

options

RequestOptionsBase

The optional parameters

callback

ServiceCallback<JobProperties>

The callback

getImportExportJob(string, ServiceCallback<JobProperties>)

function getImportExportJob(id: string, callback: ServiceCallback<JobProperties>)

Parameters

id

string

Job ID.

callback

ServiceCallback<JobProperties>

The callback

getImportExportJobs(msRest.RequestOptionsBase)

Gets the status of all import/export jobs in an iot hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities for more information.

function getImportExportJobs(options?: msRest.RequestOptionsBase): Promise<Models.JobClientGetImportExportJobsResponse>

Parameters

options
msRest.RequestOptionsBase

Returns

Promise<Models.JobClientGetImportExportJobsResponse>

Promise<Models.JobClientGetImportExportJobsResponse>

getImportExportJobs(RequestOptionsBase, ServiceCallback<JobProperties[]>)

function getImportExportJobs(options: RequestOptionsBase, callback: ServiceCallback<JobProperties[]>)

Parameters

options

RequestOptionsBase

The optional parameters

callback

ServiceCallback<JobProperties[]>

The callback

getImportExportJobs(ServiceCallback<JobProperties[]>)

function getImportExportJobs(callback: ServiceCallback<JobProperties[]>)

Parameters

callback

ServiceCallback<JobProperties[]>

The callback

getJob(string, msRest.RequestOptionsBase)

Retrieves details of a scheduled job from an IoT hub. See https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-jobs for more information.

function getJob(id: string, options?: msRest.RequestOptionsBase): Promise<Models.JobClientGetJobResponse>

Parameters

id

string

Job ID.

options
msRest.RequestOptionsBase

Returns

Promise<Models.JobClientGetJobResponse>

Promise<Models.JobClientGetJobResponse>

getJob(string, RequestOptionsBase, ServiceCallback<JobResponse>)

function getJob(id: string, options: RequestOptionsBase, callback: ServiceCallback<JobResponse>)

Parameters

id

string

Job ID.

options

RequestOptionsBase

The optional parameters

callback

ServiceCallback<JobResponse>

The callback

getJob(string, ServiceCallback<JobResponse>)

function getJob(id: string, callback: ServiceCallback<JobResponse>)

Parameters

id

string

Job ID.

callback

ServiceCallback<JobResponse>

The callback

queryJobs(JobClientQueryJobsOptionalParams, ServiceCallback<QueryResult>)

function queryJobs(options: JobClientQueryJobsOptionalParams, callback: ServiceCallback<QueryResult>)

Parameters

options
JobClientQueryJobsOptionalParams

The optional parameters

callback

ServiceCallback<QueryResult>

The callback

queryJobs(Models.JobClientQueryJobsOptionalParams)

Query an IoT hub to retrieve information regarding jobs using the IoT Hub query language. See https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-query-language for more information. Pagination of results is supported. This returns information about jobs only.

function queryJobs(options?: Models.JobClientQueryJobsOptionalParams): Promise<Models.JobClientQueryJobsResponse>

Parameters

options
Models.JobClientQueryJobsOptionalParams

Returns

Promise<Models.JobClientQueryJobsResponse>

Promise<Models.JobClientQueryJobsResponse>

queryJobs(ServiceCallback<QueryResult>)

function queryJobs(callback: ServiceCallback<QueryResult>)

Parameters

callback

ServiceCallback<QueryResult>

The callback