@sollinked/sdk
Advanced tools
Comparing version 1.1.3 to 1.1.4
import { ApiResult, AuthCallParams } from "../../types"; | ||
import { ContentCNFT } from "../ContentPass/types"; | ||
import { HomepageUser, PublicUser, User, UserCreateParams, UserUpdateParams } from "./types"; | ||
export declare const create: (params: UserCreateParams) => Promise<string | import("axios").AxiosResponse<ApiResult<User>, any>>; | ||
export declare const me: (params: AuthCallParams) => Promise<string | import("axios").AxiosResponse<ApiResult<User>, any>>; | ||
export declare const meContentPasses: (params: AuthCallParams) => Promise<string | import("axios").AxiosResponse<ApiResult<ContentCNFT[]>, any>>; | ||
export declare const get: (username: string) => Promise<string | import("axios").AxiosResponse<ApiResult<PublicUser>, any>>; | ||
@@ -6,0 +8,0 @@ export declare const search: (username: string) => Promise<string | import("axios").AxiosResponse<ApiResult<HomepageUser[]>, any>>; |
@@ -20,2 +20,10 @@ import axios from '../Services/axios.js'; | ||
}; | ||
export const meContentPasses = async (params) => { | ||
try { | ||
return await axios.post('/user/me/content_passes', params); | ||
} | ||
catch (e) { | ||
return e.response.data; | ||
} | ||
}; | ||
export const get = async (username) => { | ||
@@ -22,0 +30,0 @@ try { |
import { AuthCallParams } from "../../types"; | ||
import { UserReservation, UserReservationSetting } from "../Calendar/types"; | ||
import { Content } from "../Content/types"; | ||
import { ContentPass } from "../ContentPass/types"; | ||
import { UserGithubSetting } from "../Github/types"; | ||
@@ -28,2 +30,4 @@ import { Webhook } from "../Integration/types"; | ||
reservationSettings?: UserReservationSetting[]; | ||
contents?: Content[]; | ||
contentPasses?: ContentPass[]; | ||
webhooks?: Webhook[]; | ||
@@ -63,2 +67,4 @@ githubSettings?: UserGithubSetting[]; | ||
mailingList?: MailingList; | ||
contents?: Content[]; | ||
contentPasses?: ContentPass[]; | ||
is_verified: boolean; | ||
@@ -65,0 +71,0 @@ }; |
@@ -1,3 +0,3 @@ | ||
export declare const SOLLINKED_BACKEND_URL = "https://api.sollinked.com"; | ||
export declare const SOLLINKED_BACKEND_URL = "http://localhost:8081"; | ||
export declare const RESERVATION_STATUS_BLOCKED = -1; | ||
export declare const RESERVATION_STATUS_AVAILABLE = 0; |
@@ -1,3 +0,3 @@ | ||
export const SOLLINKED_BACKEND_URL = "https://api.sollinked.com"; | ||
export const SOLLINKED_BACKEND_URL = "http://localhost:8081"; | ||
export const RESERVATION_STATUS_BLOCKED = -1; | ||
export const RESERVATION_STATUS_AVAILABLE = 0; |
@@ -8,2 +8,4 @@ import { jsx as _jsx } from "react/jsx-runtime"; | ||
import * as mailingList from '../MailingList/index.js'; | ||
import * as content from '../Content/index.js'; | ||
import * as contentPass from '../ContentPass/index.js'; | ||
import { createContext, useCallback, useContext, useMemo, useState } from "react"; | ||
@@ -101,2 +103,16 @@ import { useCookies } from 'react-cookie'; | ||
}, [auth, signature, cookies, setCookie]); | ||
const meContentPasses = useCallback(async () => { | ||
if (!user) { | ||
throw new UninitializedError(); | ||
} | ||
if (!auth.address || !auth.message || !signature) { | ||
return; | ||
} | ||
let { address, message } = auth; | ||
let res = await account.meContentPasses({ address, message, signature }); | ||
if (typeof res === 'string') { | ||
return res; | ||
} | ||
return res.data.data; | ||
}, [user, signature, auth]); | ||
const createAccount = useCallback(async (username, customSignature) => { | ||
@@ -318,5 +334,4 @@ let sigToVerify = customSignature ?? signature; | ||
} | ||
await me(); | ||
return res; | ||
}, [user, auth, signature, me]); | ||
}, [user, auth, signature]); | ||
const testBroadcastDraft = useCallback(async (id, params) => { | ||
@@ -368,2 +383,132 @@ if (!user) { | ||
}, []); | ||
const createContent = useCallback(async (params) => { | ||
if (!user) { | ||
throw new UninitializedError(); | ||
} | ||
if (!auth.address || !auth.message || !signature) { | ||
return; | ||
} | ||
let { address, message } = auth; | ||
let res = await content.create({ address, message, signature, ...params }); | ||
if (typeof res === 'string') { | ||
return res; | ||
} | ||
await me(); | ||
return res; | ||
}, [user, auth, signature, me]); | ||
const updateContent = useCallback(async (id, params) => { | ||
if (!user) { | ||
throw new UninitializedError(); | ||
} | ||
if (!auth.address || !auth.message || !signature) { | ||
return; | ||
} | ||
let { address, message } = auth; | ||
let res = await content.update(id, { address, message, signature, ...params }); | ||
if (typeof res === 'string') { | ||
return res; | ||
} | ||
return res; | ||
}, [user, auth, signature]); | ||
const payContent = useCallback(async (id, params) => { | ||
if (!user) { | ||
throw new UninitializedError(); | ||
} | ||
if (!auth.address || !auth.message || !signature) { | ||
return; | ||
} | ||
let { address, message } = auth; | ||
let res = await content.pay(id, { address, message, signature, ...params }); | ||
if (typeof res === 'string') { | ||
return res; | ||
} | ||
return res; | ||
}, [user, auth, signature]); | ||
const publishContent = useCallback(async (id) => { | ||
if (!user) { | ||
throw new UninitializedError(); | ||
} | ||
if (!auth.address || !auth.message || !signature) { | ||
return; | ||
} | ||
let { address, message } = auth; | ||
let res = await content.publish(id, { address, message, signature }); | ||
if (typeof res === 'string') { | ||
return res; | ||
} | ||
await me(); | ||
return res; | ||
}, [user, auth, signature, me]); | ||
const unpublishContent = useCallback(async (id) => { | ||
if (!user) { | ||
throw new UninitializedError(); | ||
} | ||
if (!auth.address || !auth.message || !signature) { | ||
return; | ||
} | ||
let { address, message } = auth; | ||
let res = await content.unpublish(id, { address, message, signature }); | ||
if (typeof res === 'string') { | ||
return res; | ||
} | ||
await me(); | ||
return res; | ||
}, [user, auth, signature, me]); | ||
const getContentDraft = useCallback(async (id) => { | ||
if (!user) { | ||
throw new UninitializedError(); | ||
} | ||
if (!auth.address || !auth.message || !signature) { | ||
return; | ||
} | ||
let { address, message } = auth; | ||
return await content.getDraft(id, { address, message, signature }); | ||
}, [user, auth, signature]); | ||
const getContent = useCallback(async (username, slug) => { | ||
return await content.get(username, slug, { ...auth, signature }); | ||
}, [user, auth, signature]); | ||
const createContentPass = useCallback(async (params) => { | ||
if (!user) { | ||
throw new UninitializedError(); | ||
} | ||
if (!auth.address || !auth.message || !signature) { | ||
return; | ||
} | ||
let { address, message } = auth; | ||
let res = await contentPass.create({ address, message, signature, ...params }); | ||
if (typeof res === 'string') { | ||
return res; | ||
} | ||
await me(); | ||
return res; | ||
}, [user, auth, signature, me]); | ||
const updateContentPass = useCallback(async (id, params) => { | ||
if (!user) { | ||
throw new UninitializedError(); | ||
} | ||
if (!auth.address || !auth.message || !signature) { | ||
return; | ||
} | ||
let { address, message } = auth; | ||
let res = await contentPass.update(id, { address, message, signature, ...params }); | ||
if (typeof res === 'string') { | ||
return res; | ||
} | ||
await me(); | ||
return res; | ||
}, [user, auth, signature, me]); | ||
const payContentPass = useCallback(async (id, params) => { | ||
if (!user) { | ||
throw new UninitializedError(); | ||
} | ||
if (!auth.address || !auth.message || !signature) { | ||
return; | ||
} | ||
let { address, message } = auth; | ||
let res = await contentPass.pay(id, { address, message, signature, ...params }); | ||
if (typeof res === 'string') { | ||
return res; | ||
} | ||
return res; | ||
}, [user, auth, signature]); | ||
const setCalendarPresetPrice = useCallback(async (reservationSettings) => { | ||
@@ -522,2 +667,3 @@ if (!user) { | ||
me, | ||
meContentPasses: meContentPasses, | ||
create: createAccount, | ||
@@ -548,2 +694,16 @@ update: updateAccount, | ||
}, | ||
content: { | ||
create: createContent, | ||
update: updateContent, | ||
publish: publishContent, | ||
unpublish: unpublishContent, | ||
getDraft: getContentDraft, | ||
get: getContent, | ||
pay: payContent, | ||
}, | ||
contentPass: { | ||
create: createContentPass, | ||
update: updateContentPass, | ||
pay: payContentPass, | ||
}, | ||
calendar: { | ||
@@ -550,0 +710,0 @@ get: getUserCalendarSettings, |
@@ -9,2 +9,4 @@ import { ReactNode } from "react"; | ||
import { BroadcastParams, DraftParams, MailingList, MailingListBroadcast, UpdateMailingListPriceListParams } from "./src/MailingList/types"; | ||
import { Content, ContentCreateParams, ContentPayParams, ContentUpdateParams } from "./src/Content/types"; | ||
import { ContentCNFT, ContentPassCreateParams, ContentPassPayParams, ContentPassUpdateParams } from "./src/ContentPass/types"; | ||
export type ApiResult<T> = { | ||
@@ -41,4 +43,5 @@ success: boolean; | ||
me: (customSignature?: string) => Promise<User | undefined>; | ||
meContentPasses: () => Promise<string | ContentCNFT[] | undefined>; | ||
create: (username: string) => Promise<User | undefined>; | ||
update: (params: Omit<UserUpdateParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
update: (params: Omit<UserUpdateParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
getHomepageUsers: () => Promise<string | HomepageUser[]>; | ||
@@ -60,3 +63,3 @@ get: (username: string) => Promise<string | PublicUser>; | ||
create: () => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
updateTiers: (id: number, params: Omit<UpdateMailingListPriceListParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
updateTiers: (id: number, params: Omit<UpdateMailingListPriceListParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
get: (username: string) => Promise<string | { | ||
@@ -67,12 +70,26 @@ list: MailingList | undefined; | ||
retry: (id: number) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
broadcast: (params: Omit<BroadcastParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
saveDraft: (params: Omit<BroadcastParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<number>, any> | undefined>; | ||
updateDraft: (id: number, params: Omit<DraftParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
testDraft: (id: number, params: Omit<BroadcastParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
broadcastDraft: (id: number, params: Omit<BroadcastParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
broadcast: (params: Omit<BroadcastParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
saveDraft: (params: Omit<BroadcastParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<number>, any> | undefined>; | ||
updateDraft: (id: number, params: Omit<DraftParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
testDraft: (id: number, params: Omit<BroadcastParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
broadcastDraft: (id: number, params: Omit<BroadcastParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
getDraft: (id: number) => Promise<string | AxiosResponse<ApiResult<MailingListBroadcast>, any> | undefined>; | ||
}; | ||
content?: { | ||
create: (params: Omit<ContentCreateParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
update: (id: number, params: Omit<ContentUpdateParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
publish: (id: number) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
unpublish: (id: number) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
getDraft: (id: number) => Promise<string | AxiosResponse<ApiResult<Content>, any> | undefined>; | ||
get: (username: string, slug: string) => Promise<string | Content>; | ||
pay: (id: number, params: Omit<ContentPayParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<Content>, any> | undefined>; | ||
}; | ||
contentPass?: { | ||
create: (params: Omit<ContentPassCreateParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
update: (id: number, params: Omit<ContentPassUpdateParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
pay: (id: number, params: Omit<ContentPassPayParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
}; | ||
calendar?: { | ||
setPresetPrice: (reservationSettings: UserReservationSetting[]) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
setCustomPrice: (params: Omit<UpdateUserReservationParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
setCustomPrice: (params: Omit<UpdateUserReservationParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
get: (username: string) => Promise<string | { | ||
@@ -91,4 +108,4 @@ reservations: UserReservation[] | undefined; | ||
github?: { | ||
create: (params: Omit<CreateGitHubSettingParams, "address" | "message" | "signature" | "user_id">) => Promise<string | AxiosResponse<ApiResult<string>, any> | undefined>; | ||
update: (githubSettingId: number, params: Omit<UpdateGitHubSettingParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<string>, any> | undefined>; | ||
create: (params: Omit<CreateGitHubSettingParams, keyof AuthCallParams | "user_id">) => Promise<string | AxiosResponse<ApiResult<string>, any> | undefined>; | ||
update: (githubSettingId: number, params: Omit<UpdateGitHubSettingParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<string>, any> | undefined>; | ||
toggle: (githubSettingId: number) => Promise<string | AxiosResponse<ApiResult<string>, any> | undefined>; | ||
@@ -103,3 +120,3 @@ newIssue: (params: NewGithubIssueParams) => Promise<string | AxiosResponse<ApiResult<string>, any>>; | ||
integration?: { | ||
update: (webhookId: number, params: Omit<UpdateIntegrationParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
update: (webhookId: number, params: Omit<UpdateIntegrationParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
test: (webhookId: number) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
@@ -106,0 +123,0 @@ }; |
{ | ||
"name": "@sollinked/sdk", | ||
"version": "1.1.3", | ||
"version": "1.1.4", | ||
"description": "SDK for Sollinked", | ||
@@ -5,0 +5,0 @@ "main": "./dist/index.js", |
import { ApiResult, AuthCallParams } from "../../types"; | ||
import { ContentCNFT } from "../ContentPass/types"; | ||
import axios from '../Services/axios.js'; | ||
@@ -29,2 +30,13 @@ import { HomepageUser, PublicUser, User, UserCreateParams, UserUpdateParams } from "./types"; | ||
// get own content pass | ||
export const meContentPasses = async(params: AuthCallParams) => { | ||
try { | ||
return await axios.post<ApiResult<ContentCNFT[]>>('/user/me/content_passes', params); | ||
} | ||
catch(e: any) { | ||
return e.response.data as string; | ||
} | ||
} | ||
// get public profile | ||
@@ -31,0 +43,0 @@ export const get = async(username: string) => { |
import { AuthCallParams } from "../../types"; | ||
import { UserReservation, UserReservationSetting } from "../Calendar/types"; | ||
import { Content } from "../Content/types"; | ||
import { ContentPass } from "../ContentPass/types"; | ||
import { UserGithubSetting } from "../Github/types"; | ||
@@ -29,2 +31,4 @@ import { Webhook } from "../Integration/types"; | ||
reservationSettings?: UserReservationSetting[]; | ||
contents?: Content[]; | ||
contentPasses?: ContentPass[]; | ||
webhooks?: Webhook[]; | ||
@@ -67,2 +71,4 @@ githubSettings?: UserGithubSetting[]; | ||
mailingList?: MailingList; | ||
contents?: Content[]; | ||
contentPasses?: ContentPass[]; | ||
is_verified: boolean; | ||
@@ -69,0 +75,0 @@ } |
@@ -1,4 +0,4 @@ | ||
export const SOLLINKED_BACKEND_URL = "https://api.sollinked.com"; | ||
// export const SOLLINKED_BACKEND_URL = "http://localhost:8081"; | ||
// export const SOLLINKED_BACKEND_URL = "https://api.sollinked.com"; | ||
export const SOLLINKED_BACKEND_URL = "http://localhost:8081"; | ||
export const RESERVATION_STATUS_BLOCKED = -1; | ||
export const RESERVATION_STATUS_AVAILABLE = 0; |
41
types.ts
@@ -9,2 +9,4 @@ import { ReactNode } from "react"; | ||
import { BroadcastParams, DraftParams, MailingList, MailingListBroadcast, UpdateMailingListPriceListParams } from "./src/MailingList/types"; | ||
import { Content, ContentCreateParams, ContentPayParams, ContentUpdateParams } from "./src/Content/types"; | ||
import { ContentCNFT, ContentPassCreateParams, ContentPassPayParams, ContentPassUpdateParams } from "./src/ContentPass/types"; | ||
@@ -46,4 +48,5 @@ export type ApiResult<T> = { | ||
me: (customSignature?: string) => Promise<User | undefined>; | ||
meContentPasses: () => Promise<string | ContentCNFT[] | undefined>; | ||
create: (username: string) => Promise<User | undefined>; | ||
update: (params: Omit<UserUpdateParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
update: (params: Omit<UserUpdateParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
getHomepageUsers: () => Promise<string | HomepageUser[]>; | ||
@@ -65,3 +68,3 @@ get: (username: string) => Promise<string | PublicUser>; | ||
create: () => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
updateTiers: (id: number, params: Omit<UpdateMailingListPriceListParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
updateTiers: (id: number, params: Omit<UpdateMailingListPriceListParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
get: (username: string) => Promise<string | { | ||
@@ -72,12 +75,26 @@ list: MailingList | undefined; | ||
retry: (id: number) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
broadcast: (params: Omit<BroadcastParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
saveDraft: (params: Omit<BroadcastParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<number>, any> | undefined>; | ||
updateDraft: (id: number, params: Omit<DraftParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
testDraft: (id: number, params: Omit<BroadcastParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
broadcastDraft: (id: number, params: Omit<BroadcastParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
broadcast: (params: Omit<BroadcastParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
saveDraft: (params: Omit<BroadcastParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<number>, any> | undefined>; | ||
updateDraft: (id: number, params: Omit<DraftParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
testDraft: (id: number, params: Omit<BroadcastParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
broadcastDraft: (id: number, params: Omit<BroadcastParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
getDraft: (id: number) => Promise<string | AxiosResponse<ApiResult<MailingListBroadcast>, any> | undefined>; | ||
} | ||
}, | ||
content?: { | ||
create: (params: Omit<ContentCreateParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
update: (id: number, params: Omit<ContentUpdateParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
publish: (id: number) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
unpublish: (id: number) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
getDraft: (id: number) => Promise<string | AxiosResponse<ApiResult<Content>, any> | undefined>; | ||
get: (username: string, slug: string) => Promise<string | Content>; | ||
pay: (id: number, params: Omit<ContentPayParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<Content>, any> | undefined>; | ||
}, | ||
contentPass?: { | ||
create: (params: Omit<ContentPassCreateParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
update: (id: number, params: Omit<ContentPassUpdateParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
pay: (id: number, params: Omit<ContentPassPayParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
}, | ||
calendar?: { | ||
setPresetPrice: (reservationSettings: UserReservationSetting[]) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
setCustomPrice: (params: Omit<UpdateUserReservationParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
setCustomPrice: (params: Omit<UpdateUserReservationParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
get: (username: string) => Promise<string | { | ||
@@ -96,4 +113,4 @@ reservations: UserReservation[] | undefined; | ||
github?: { | ||
create: (params: Omit<CreateGitHubSettingParams, "address" | "message" | "signature" | "user_id">) => Promise<string | AxiosResponse<ApiResult<string>, any> | undefined>; | ||
update: (githubSettingId: number, params: Omit<UpdateGitHubSettingParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<string>, any> | undefined>; | ||
create: (params: Omit<CreateGitHubSettingParams, keyof AuthCallParams | "user_id">) => Promise<string | AxiosResponse<ApiResult<string>, any> | undefined>; | ||
update: (githubSettingId: number, params: Omit<UpdateGitHubSettingParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<string>, any> | undefined>; | ||
toggle: (githubSettingId: number) => Promise<string | AxiosResponse<ApiResult<string>, any> | undefined>; | ||
@@ -108,3 +125,3 @@ newIssue: (params: NewGithubIssueParams) => Promise<string | AxiosResponse<ApiResult<string>, any>>; | ||
integration?: { | ||
update: (webhookId: number, params: Omit<UpdateIntegrationParams, "address" | "message" | "signature">) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
update: (webhookId: number, params: Omit<UpdateIntegrationParams, keyof AuthCallParams>) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
test: (webhookId: number) => Promise<string | AxiosResponse<ApiResult<undefined>, any> | undefined>; | ||
@@ -111,0 +128,0 @@ } |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
150289
70
3956