2022-02-14 16:20:29 +00:00
|
|
|
import type { IInvite } from '../../IInvite';
|
2022-03-08 16:25:27 +00:00
|
|
|
import type { IServerRoom } from '../../IRoom';
|
2022-02-14 16:20:29 +00:00
|
|
|
|
|
|
|
export type InvitesEndpoints = {
|
|
|
|
listInvites: {
|
|
|
|
GET: () => Array<IInvite>;
|
|
|
|
};
|
|
|
|
'removeInvite/:_id': {
|
|
|
|
DELETE: () => void;
|
|
|
|
};
|
|
|
|
'/v1/useInviteToken': {
|
|
|
|
POST: (params: { token: string }) => {
|
|
|
|
room: {
|
2022-03-08 16:25:27 +00:00
|
|
|
rid: IServerRoom['_id'];
|
|
|
|
prid: IServerRoom['prid'];
|
|
|
|
fname: IServerRoom['fname'];
|
|
|
|
name: IServerRoom['name'];
|
|
|
|
t: IServerRoom['t'];
|
2022-02-14 16:20:29 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
'/v1/validateInviteToken': {
|
|
|
|
POST: (params: { token: string }) => { valid: boolean };
|
|
|
|
};
|
|
|
|
};
|