Skip to content

Commit

Permalink
Add more exports to client (#507)
Browse files Browse the repository at this point in the history
* updated exports

* add report

* add changeset
  • Loading branch information
ssanjay1 authored Jul 23, 2024
1 parent 3615522 commit 8cff4f0
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 5 deletions.
5 changes: 5 additions & 0 deletions .changeset/spotty-onions-march.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@osdk/client": minor
---

Adding more package exports
13 changes: 9 additions & 4 deletions etc/client.report.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,13 @@ import { ActionValidationResponse } from '@osdk/client.api';
import { ApplyActionOptions } from '@osdk/client.api';
import { ApplyBatchActionOptions } from '@osdk/client.api';
import type { Attachment } from '@osdk/client.api';
import type { AttachmentUpload } from '@osdk/client.api';
import type { GreaterThan } from 'type-fest';
import type { GreaterThanOrEqual } from 'type-fest';
import type { InterfaceDefinition } from '@osdk/api';
import { InterfaceObjectSet } from '@osdk/client.api';
import type { IsEqual } from 'type-fest';
import { isOk } from '@osdk/client.api';
import type { LessThan } from 'type-fest';
import type { Logger } from 'pino';
import { NOOP } from '@osdk/client.api';
Expand All @@ -31,6 +33,7 @@ import { PageResult } from '@osdk/client.api';
import { PalantirApiError } from '@osdk/shared.net.errors';
import type { QueryDefinition } from '@osdk/api';
import type { QuerySignatureFromDef } from '@osdk/client.api';
import { Result } from '@osdk/client.api';
import type { SharedClient } from '@osdk/shared.client';
import { SharedClientContext } from '@osdk/shared.client';
import type { VersionBound } from '@osdk/api';
Expand Down Expand Up @@ -70,6 +73,9 @@ export interface Client extends SharedClient<MinimalClient> {
// @public (undocumented)
export function createAttachmentFromRid(client: MinimalClient, rid: string): Attachment;

// @public (undocumented)
export function createAttachmentUpload(data: Blob, name: string): AttachmentUpload;

// @public (undocumented)
export const createClient: (baseUrl: string, ontologyRid: string | Promise<string>, tokenProvider: () => Promise<string>, options?: {
logger?: Logger;
Expand All @@ -85,10 +91,7 @@ export function createPlatformClient(baseUrl: string, tokenProvider: () => Promi

export { InterfaceObjectSet }

// @public (undocumented)
export function isOk(result: ResultOrError<any>): result is {
type: "ok";
};
export { isOk }

export { NOOP }

Expand All @@ -104,6 +107,8 @@ export { PageResult }

export { PalantirApiError }

export { Result }

// @public (undocumented)
export type ResultOrError<T extends object> = ({
type: "ok";
Expand Down
5 changes: 4 additions & 1 deletion packages/client/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,19 @@ export type {
OsdkActionParameters,
OsdkObject,
PageResult,
Result,
WhereClause,
} from "@osdk/client.api";

export { isOk } from "@osdk/client.api";
export { PalantirApiError } from "@osdk/shared.net.errors";

export type { Client } from "./Client.js";
export { createClient } from "./createClient.js";
export { createPlatformClient } from "./createPlatformClient.js";

export { createAttachmentFromRid } from "./createAttachmentFromRid.js";
export { createAttachmentUpload } from "./object/AttachmentUpload.js";

export { ActionValidationError } from "./actions/ActionValidationError.js";
export { isOk } from "./ResultOrError.js";
export type { ResultOrError } from "./ResultOrError.js";

0 comments on commit 8cff4f0

Please sign in to comment.