UNPKG

@amityco/ts-sdk-react-native

Version:

Amity Social Cloud Typescript SDK

29 lines 970 B
/** * ```js * import { PostRepository } from '@amityco/ts-sdk-react-native' * const created = await PostRepository.createRoomPost({ * targetType: 'user', * targetId: 'foobar', * data: { text: 'hello world', title: 'Room Title', roomId: 'roomId123' } * })) * ``` * * Creates an {@link Amity.Post} * * @param bundle The data necessary to create a new {@link Amity.Post} * @returns The newly created {@link Amity.Post} * * @category Post API * @async */ export declare const createRoomPost: <T extends string>(bundle: Pick<Amity.Post<T>, "targetId" | "targetType"> & Partial<Pick<Amity.Post<T>, "tags" | "metadata" | "mentionees" | "hashtags">> & { data: { roomId: string; } & { [k: string]: any; }; links?: Amity.Link[] | undefined; productTags?: Amity.ProductTag[] | null | undefined; pinnedProductId?: string | undefined; }) => Promise<Amity.Cached<Amity.Post>>; //# sourceMappingURL=createRoomPost.d.ts.map