UseGetApi
katanakit-js / useGetApi
Function: useGetApi()
Section titled “Function: useGetApi()”function useGetApi<T>( apiName, endpointName, urlOptions?): Promise<FetchResult<T>>;Defined in: core/services/http.service.ts:703
GET helper over a registered API endpoint. Alias for useGet.
Type Parameters
Section titled “Type Parameters”| Type Parameter | Default type |
|---|---|
T |
unknown |
Parameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
apiName |
string |
The registered API key. |
endpointName |
string |
The endpoint key within the API. |
urlOptions? |
UrlOptions |
Optional URL building options. |
Returns
Section titled “Returns”Promise<FetchResult<T>>
A FetchResult with data or error.