dot-wrap_as_api_response: Package-internal HTTP-response helper

.wrap_as_api_responseR Documentation

Package-internal HTTP-response helper

Description

Used for overriding the OpenAPI-autogenerated HTTP-response handling.

Usage

.wrap_as_api_response(resp)

Arguments

resp

A response S3 object e.g. from httr:GET.

Details

Makes the handling compatible with TileDB REST-server response format; surfaces error messages back to the user. Not intended to be exported from this package; for package-internal use only.

Value

An object of type ApiResponse. In the success case (HTTP 2xx) its content slot is the raw HTTP body. In the failure case (otherwise) its content slot is error-text from the server.


TileDB-Inc/TileDB-Cloud-R documentation built on July 18, 2024, 3:33 p.m.