Skip to content

Commit

Permalink
Release 0.0.10
Browse files Browse the repository at this point in the history
  • Loading branch information
fern-api[bot] committed Dec 16, 2024
1 parent 0f263cb commit 4927b47
Show file tree
Hide file tree
Showing 22 changed files with 98 additions and 66 deletions.
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,7 @@ await client.referrals.upsert({
{
question: "question",
id: "id",
answer: {
key: "value",
},
answer: "answer",
},
],
});
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@opengovsg/refx-ts-sdk",
"version": "0.0.9",
"version": "0.0.10",
"private": false,
"repository": "https://github.com/opengovsg/refer-ts-sdk",
"main": "./index.js",
Expand Down
6 changes: 3 additions & 3 deletions reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,8 @@ await client.eligibility.get({

```typescript
await client.referrals.list({
offset: 1.1,
pageSize: 1.1,
hciCode: "hciCode",
});
```
Expand Down Expand Up @@ -140,9 +142,7 @@ await client.referrals.upsert({
{
question: "question",
id: "id",
answer: {
key: "value",
},
answer: "answer",
},
],
});
Expand Down
4 changes: 2 additions & 2 deletions src/api/resources/eligibility/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ export class Eligibility {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down
4 changes: 2 additions & 2 deletions src/api/resources/health/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ export class Health {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down
4 changes: 2 additions & 2 deletions src/api/resources/notes/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ export class Notes {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down
12 changes: 6 additions & 6 deletions src/api/resources/offerings/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ export class Offerings {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -107,8 +107,8 @@ export class Offerings {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -178,8 +178,8 @@ export class Offerings {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down
4 changes: 2 additions & 2 deletions src/api/resources/public/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ export class Public {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down
52 changes: 23 additions & 29 deletions src/api/resources/referrals/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ export class Referrals {
*
* @example
* await client.referrals.list({
* offset: 1.1,
* pageSize: 1.1,
* hciCode: "hciCode"
* })
*/
Expand All @@ -45,14 +47,8 @@ export class Referrals {
): Promise<ReferralExchange.PaginatedReferralsDto> {
const { offset, pageSize, hciCode, status, role } = request;
const _queryParams: Record<string, string | string[] | object | object[]> = {};
if (offset != null) {
_queryParams["offset"] = offset.toString();
}

if (pageSize != null) {
_queryParams["pageSize"] = pageSize.toString();
}

_queryParams["offset"] = offset.toString();
_queryParams["pageSize"] = pageSize.toString();
_queryParams["hciCode"] = hciCode;
if (status != null) {
if (Array.isArray(status)) {
Expand All @@ -76,8 +72,8 @@ export class Referrals {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -142,9 +138,7 @@ export class Referrals {
* formResponses: [{
* question: "question",
* id: "id",
* answer: {
* "key": "value"
* }
* answer: "answer"
* }]
* })
*/
Expand All @@ -162,8 +156,8 @@ export class Referrals {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -231,8 +225,8 @@ export class Referrals {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -294,8 +288,8 @@ export class Referrals {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -358,8 +352,8 @@ export class Referrals {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -425,8 +419,8 @@ export class Referrals {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -492,8 +486,8 @@ export class Referrals {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -559,8 +553,8 @@ export class Referrals {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -622,8 +616,8 @@ export class Referrals {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,7 @@ import * as ReferralExchange from "../../../../index";
* formResponses: [{
* question: "question",
* id: "id",
* answer: {
* "key": "value"
* }
* answer: "answer"
* }]
* }
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,20 @@ import * as ReferralExchange from "../../../../index";
/**
* @example
* {
* offset: 1.1,
* pageSize: 1.1,
* hciCode: "hciCode"
* }
*/
export interface ReferralsListRequest {
/**
* Offset for pagination
*/
offset?: number;
offset: number;
/**
* Number of items per page
*/
pageSize?: number;
pageSize: number;
/**
* To identify the requesting institution
*/
Expand Down
8 changes: 4 additions & 4 deletions src/api/resources/webhooks/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ export class Webhooks {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down Expand Up @@ -105,8 +105,8 @@ export class Webhooks {
headers: {
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@opengovsg/refx-ts-sdk",
"X-Fern-SDK-Version": "0.0.9",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.9",
"X-Fern-SDK-Version": "0.0.10",
"User-Agent": "@opengovsg/refx-ts-sdk/0.0.10",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
...(await this._getCustomAuthorizationHeaders()),
Expand Down
4 changes: 3 additions & 1 deletion src/api/types/FormResponse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@
* This file was auto-generated by Fern from our API Definition.
*/

import * as ReferralExchange from "../index";

export interface FormResponse {
question: string;
id: string;
answer: Record<string, unknown>;
answer: ReferralExchange.FormResponseAnswer;
}
5 changes: 5 additions & 0 deletions src/api/types/FormResponseAnswer.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/**
* This file was auto-generated by Fern from our API Definition.
*/

export type FormResponseAnswer = string | string[] | number;
4 changes: 3 additions & 1 deletion src/api/types/InstitutionCoreDto.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,12 @@
* This file was auto-generated by Fern from our API Definition.
*/

import * as ReferralExchange from "../index";

export interface InstitutionCoreDto {
hciCode: string;
name: string;
system: string;
system: ReferralExchange.InstitutionCoreDtoSystem;
block: string;
streetName: string;
buildingName?: string;
Expand Down
11 changes: 11 additions & 0 deletions src/api/types/InstitutionCoreDtoSystem.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/**
* This file was auto-generated by Fern from our API Definition.
*/

export type InstitutionCoreDtoSystem = "HAS" | "PartnersBuddy" | "Refer" | "EmailAck";
export const InstitutionCoreDtoSystem = {
Has: "HAS",
PartnersBuddy: "PartnersBuddy",
Refer: "Refer",
EmailAck: "EmailAck",
} as const;
4 changes: 2 additions & 2 deletions src/api/types/PaginatedQuery.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

export interface PaginatedQuery {
/** Offset for pagination */
offset?: number;
offset: number;
/** Number of items per page */
pageSize?: number;
pageSize: number;
}
6 changes: 4 additions & 2 deletions src/api/types/ReferralAmendedMetadata.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
* This file was auto-generated by Fern from our API Definition.
*/

import * as ReferralExchange from "../index";

export interface ReferralAmendedMetadata {
before: Record<string, unknown>;
after: Record<string, unknown>;
before: ReferralExchange.ReferralAmendedMetadataBefore;
after: ReferralExchange.ReferralAmendedMetadataAfter;
}
7 changes: 7 additions & 0 deletions src/api/types/ReferralAmendedMetadataAfter.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
/**
* This file was auto-generated by Fern from our API Definition.
*/

export interface ReferralAmendedMetadataAfter {
timeslotStartAt?: number;
}
7 changes: 7 additions & 0 deletions src/api/types/ReferralAmendedMetadataBefore.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
/**
* This file was auto-generated by Fern from our API Definition.
*/

export interface ReferralAmendedMetadataBefore {
timeslotStartAt?: number;
}
Loading

0 comments on commit 4927b47

Please sign in to comment.