feat: Route to update group subject

This commit is contained in:
Davidson Gomes
2023-06-12 12:02:10 -03:00
parent 75b48aa8ac
commit a28bbce1f9
7 changed files with 62 additions and 5 deletions

View File

@@ -680,7 +680,7 @@ export const toggleEphemeralSchema: JSONSchema7 = {
...isNotEmpty('groupJid', 'expiration'),
};
export const updateGroupPicture: JSONSchema7 = {
export const updateGroupPictureSchema: JSONSchema7 = {
$id: v4(),
type: 'object',
properties: {
@@ -691,6 +691,17 @@ export const updateGroupPicture: JSONSchema7 = {
...isNotEmpty('groupJid', 'image'),
};
export const updateGroupSubjectSchema: JSONSchema7 = {
$id: v4(),
type: 'object',
properties: {
groupJid: { type: 'string' },
subject: { type: 'string' },
},
required: ['groupJid', 'subject'],
...isNotEmpty('groupJid', 'subject'),
};
// Webhook Schema
export const webhookSchema: JSONSchema7 = {
$id: v4(),