UNPKG

splitwise

Version:

A TypeScript SDK for the Splitwise API.

24 lines 720 B
import { BaseResource } from './base.js'; export class Comments extends BaseResource { async list(params, overrides) { return this.http.get('/get_comments', { query: { expenseId: params.expenseId }, unwrapKey: 'comments', ...overrides, }); } async create(params, overrides) { return this.http.post('/create_comment', { body: { ...params }, unwrapKey: 'comment', ...overrides, }); } async delete(params, overrides) { return this.http.post(`/delete_comment/${params.id}`, { unwrapKey: 'comment', ...overrides, }); } } //# sourceMappingURL=comments.js.map