mirror of
https://github.com/glitch-soc/mastodon.git
synced 2024-11-24 00:54:02 -05:00
11 lines
404 B
TypeScript
11 lines
404 B
TypeScript
import { apiRequestPost } from 'mastodon/api';
|
|
import type { Status, StatusVisibility } from 'mastodon/models/status';
|
|
|
|
export const apiReblog = (statusId: string, visibility: StatusVisibility) =>
|
|
apiRequestPost<{ reblog: Status }>(`v1/statuses/${statusId}/reblog`, {
|
|
visibility,
|
|
});
|
|
|
|
export const apiUnreblog = (statusId: string) =>
|
|
apiRequestPost<Status>(`v1/statuses/${statusId}/unreblog`);
|