Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions packages/clients/src/helpers/json.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ export const isJSON = (obj: unknown): obj is JSON => {
)
}

/**
* Validates an unknown object is a JSON Object.
*
* @internal
*/
export const isJSONObject = (obj: unknown): obj is JSONObject => {
const objT: string = typeof obj

Expand Down
7 changes: 4 additions & 3 deletions packages/clients/src/internals.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
export { API } from './scw/api'
export { isJSONObject } from './helpers/json'
export { waitForResource } from './internal/async/interval-retrier'
export { authenticateWithSessionToken } from './scw/auth'
export type { RequestInterceptor } from './internal/interceptors/request'
export type { ResponseInterceptor } from './internal/interceptors/response'
export { API } from './scw/api'
export { authenticateWithSessionToken } from './scw/auth'
export type { DefaultValues } from './scw/client-ini-profile'
export type { ServiceInfo } from './scw/custom-types'
export {
marshalScwFile,
marshalMoney,
Expand All @@ -15,6 +15,7 @@ export {
unmarshalTimeSeries,
unmarshalTimeSeriesPoint,
} from './scw/custom-marshalling'
export type { ServiceInfo } from './scw/custom-types'
export {
resolveOneOf,
unmarshalDate,
Expand Down