BentleyCloudRpcProtocol Class

An http protocol for Bentley cloud RPC interface deployments.

Extends

Methods

Name Description
constructor(configuration: RpcConfiguration): BentleyCloudRpcProtocol Constructs an HTTP protocol.  
getOperationFromPath(path: string): SerializedRpcOperation Returns the operation specified by an OpenAPI-compatible URI path.  
inflateToken(tokenFromBody: IModelTokenProps, request: SerializedRpcRequest): IModelTokenProps Inflates the IModelToken from the URL path for each request on the backend.  
supplyPathForOperation(operation: RpcOperation, request: RpcRequest | undefined): string Supplies the OpenAPI-compatible URI path for an RPC operation.  

Inherited methods

Name Inherited from Description
fulfill(request: SerializedRpcRequest): Promise<RpcRequestFulfillment> RpcProtocol Obtains the implementation result on the backend for an RPC operation request.
getCode(status: RpcRequestStatus): number WebAppRpcProtocol Supplies the protocol-specific code corresponding to a status value.
getStatus(code: number): RpcRequestStatus WebAppRpcProtocol Supplies the status corresponding to a protocol-specific code value.
handleOpenApiDescriptionRequest(_req: HttpServerRequest, res: HttpServerResponse): void WebAppRpcProtocol Convenience handler for an OpenAPI description request for an HTTP server.
handleOperationGetRequest(req: HttpServerRequest, res: HttpServerResponse): Promise<void> WebAppRpcProtocol Convenience handler for an RPC operation get request for an HTTP server.
handleOperationPostRequest(req: HttpServerRequest, res: HttpServerResponse): Promise<void> WebAppRpcProtocol Convenience handler for an RPC operation post request for an HTTP server.
isTimeout(code: number): boolean WebAppRpcProtocol Whether an HTTP status code indicates a request timeout.
serialize(request: RpcRequest): Promise<SerializedRpcRequest> RpcProtocol Serializes a request.
computeContentType(httpType: string | null | undefined): RpcContentType Static WebAppRpcProtocol Converts an HTTP content type value to an RPC content type value.

Properties

Name Type Description
checkToken boolean    

Inherited properties

Name Type Inherited from Description
configuration RpcConfiguration RpcProtocol The configuration for the protocol.
events Static BeEvent<RpcProtocolEventHandler> RpcProtocol Events raised by all protocols.
events BeEvent<RpcProtocolEventHandler> RpcProtocol Events raised by the protocol.
info Abstract OpenAPIInfo WebAppRpcProtocol The OpenAPI-compatible info object for this protocol.
invocationType RpcInvocation RpcProtocol The RPC invocation class for this protocol.
pathPrefix string WebAppRpcProtocol An optional prefix for RPC operation URI paths.
preserveStreams boolean WebAppRpcProtocol  
requestType WebAppRpcRequest WebAppRpcProtocol The RPC request class for this protocol.
transferChunkThreshold number RpcProtocol If greater than zero, specifies where to break large binary request payloads.

Object Literals

Name Description
serializedClientRequestContextHeaderNames The name of various HTTP request headers based on client's request context

Defined in

Last Updated: 10 September, 2019