UNPKG

@iotize/device-client.js

Version:

IoTize Device client for Javascript

169 lines (168 loc) 6.79 kB
/** * This file has been generated * DO NOT EDIT, IT MAY BE OVERWRITTEN */ import { Client, Response, ApiConfig } from "../import-adapter"; import { AbstractService, ServiceCallType } from '../abstract-service'; import { ScramLoginParams } from '../../all-models'; import { ScramLoginResponseBody } from '../../all-models'; import { EncryptedIVResponse } from '../../all-models'; import { EncryptedIVCommand } from '../../all-models'; export declare class ScramService extends AbstractService { constructor(client: Client, apiConfig: ApiConfig); resources: { [key: string]: ServiceCallType; }; /** * Get scram hash iteration counter * Scram conf iteration counter (i) to be read by client before starting scram login process * LWM2M path: /1024//42 * @tapVersion(">=1.11") * @return number api call */ getHashIteration(): Promise<Response<number>>; /** * Get scram hash iteration counter * Scram conf iteration counter (i) to be read by client before starting scram login process * LWM2M path: /1024//42 * @tapVersion(">=1.11") * @return call options */ getHashIterationCall(): ServiceCallType; /** * Start scram communication * Demande d&#39;une clé aléatoire et initiation d&#39;une session CCOM cryptée utilisant ce RNG comme clé de cryptage. Accessible uniquement en NFC. * LWM2M path: /1024//47 * @tapVersion(">=1.11") * @return Uint8Array api call */ initialize(): Promise<Response<Uint8Array>>; /** * Start scram communication * Demande d&#39;une clé aléatoire et initiation d&#39;une session CCOM cryptée utilisant ce RNG comme clé de cryptage. Accessible uniquement en NFC. * LWM2M path: /1024//47 * @tapVersion(">=1.11") * @return call options */ initializeCall(): ServiceCallType; /** * First command to initiate scram login, for client to send login and nonce to IoTize, and IoTize to return user salt, user iteration counter (j) and combined nonce * First command to initiate scram login, for client to send login and nonce to IoTize, and IoTize to return user salt, user iteration counter (j) and combined nonce * LWM2M path: /1024//40 * Body converter id: "ScramLoginParams" * @tapVersion(">=1.0") * @param params input * @return ScramLoginResponseBody api call */ login(params: ScramLoginParams): Promise<Response<ScramLoginResponseBody>>; /** * First command to initiate scram login, for client to send login and nonce to IoTize, and IoTize to return user salt, user iteration counter (j) and combined nonce * First command to initiate scram login, for client to send login and nonce to IoTize, and IoTize to return user salt, user iteration counter (j) and combined nonce * LWM2M path: /1024//40 * Body converter id: "ScramLoginParams" * @tapVersion(">=1.0") * @param params input * @return call options */ loginCall(params: ScramLoginParams): ServiceCallType; /** * Scram login proof * Second command to finalize scram login, for client to send ClientProof and combined nonce * LWM2M path: /1024//41 * Body converter id: "Bytes" * @tapVersion(">=1.0") * @param params input * @return Uint8Array api call */ loginProof(params: Uint8Array): Promise<Response<Uint8Array>>; /** * Scram login proof * Second command to finalize scram login, for client to send ClientProof and combined nonce * LWM2M path: /1024//41 * Body converter id: "Bytes" * @tapVersion(">=1.0") * @param params input * @return call options */ loginProofCall(params: Uint8Array): ServiceCallType; /** * Set scram hash iteration counter * * LWM2M path: /1024//42 * Body converter id: "integer_uint16" * @tapVersion(">=1.11") * @param data input * @return void api call */ putHashIteration(data: number): Promise<Response<void>>; /** * Set scram hash iteration counter * * LWM2M path: /1024//42 * Body converter id: "integer_uint16" * @tapVersion(">=1.11") * @param data input * @return call options */ putHashIterationCall(data: number): ServiceCallType; /** * Communication channel * Encrypted communication ressource, for sending/receiving commands/responses after the SCRAM or CCOM session is established. * LWM2M path: /1024//48 * Body converter id: "Bytes" * @tapVersion(">=1.11") * @param data input * @return Uint8Array api call */ send(data: Uint8Array): Promise<Response<Uint8Array>>; /** * Communication channel * Encrypted communication ressource, for sending/receiving commands/responses after the SCRAM or CCOM session is established. * LWM2M path: /1024//48 * Body converter id: "Bytes" * @tapVersion(">=1.11") * @param data input * @return call options */ sendCall(data: Uint8Array): ServiceCallType; /** * Communication channel with encryption initialization vectory * Encrypted communication ressource with initialization vector, for sending/receiving commands/responses after the SCRAM or CCOM session is established. * LWM2M path: /1024//44 * Body converter id: "EncryptedIVCommand" * @tapVersion(">=1.85") * @param data input * @return EncryptedIVResponse api call */ sendWithIV(data: EncryptedIVCommand): Promise<Response<EncryptedIVResponse>>; /** * Communication channel with encryption initialization vectory * Encrypted communication ressource with initialization vector, for sending/receiving commands/responses after the SCRAM or CCOM session is established. * LWM2M path: /1024//44 * Body converter id: "EncryptedIVCommand" * @tapVersion(">=1.85") * @param data input * @return call options */ sendWithIVCall(data: EncryptedIVCommand): ServiceCallType; /** * Give encryption initialization vector to the device. The device returns its own initialization vector * * LWM2M path: /1024//45 * Body converter id: "Bytes" * @tapVersion(">=1.85") * @param data input * @return Uint8Array api call */ setInitializationVector(data: Uint8Array): Promise<Response<Uint8Array>>; /** * Give encryption initialization vector to the device. The device returns its own initialization vector * * LWM2M path: /1024//45 * Body converter id: "Bytes" * @tapVersion(">=1.85") * @param data input * @return call options */ setInitializationVectorCall(data: Uint8Array): ServiceCallType; }