|
1483 | 1483 | } |
1484 | 1484 | } |
1485 | 1485 | ], |
| 1486 | + "requestBody": { |
| 1487 | + "content": { |
| 1488 | + "application/json": { |
| 1489 | + "schema": { |
| 1490 | + "$ref": "#/components/schemas/DataCreateInvite" |
| 1491 | + } |
| 1492 | + } |
| 1493 | + }, |
| 1494 | + "required": true |
| 1495 | + }, |
1486 | 1496 | "responses": { |
1487 | 1497 | "default": { |
1488 | 1498 | "description": "An error occurred.", |
|
6838 | 6848 | "required": [ |
6839 | 6849 | "body_limit_size", |
6840 | 6850 | "group_size", |
| 6851 | + "max_invite_duration_days", |
6841 | 6852 | "message_embeds", |
6842 | 6853 | "message_reactions", |
6843 | 6854 | "message_replies", |
|
6898 | 6909 | "description": "New user hours", |
6899 | 6910 | "type": "integer", |
6900 | 6911 | "format": "int64" |
| 6912 | + }, |
| 6913 | + "max_invite_duration_days": { |
| 6914 | + "description": "Number of days after creation before an invite expires", |
| 6915 | + "type": "integer", |
| 6916 | + "format": "int64" |
6901 | 6917 | } |
6902 | 6918 | } |
6903 | 6919 | }, |
|
9847 | 9863 | "channel", |
9848 | 9864 | "creator", |
9849 | 9865 | "server", |
9850 | | - "type" |
| 9866 | + "type", |
| 9867 | + "uses" |
9851 | 9868 | ], |
9852 | 9869 | "properties": { |
9853 | 9870 | "type": { |
|
9871 | 9888 | "channel": { |
9872 | 9889 | "description": "Id of the server channel this invite points to", |
9873 | 9890 | "type": "string" |
| 9891 | + }, |
| 9892 | + "max_uses": { |
| 9893 | + "description": "Maximum number of times this invite can be used", |
| 9894 | + "type": "integer", |
| 9895 | + "format": "uint64", |
| 9896 | + "minimum": 0.0, |
| 9897 | + "nullable": true |
| 9898 | + }, |
| 9899 | + "uses": { |
| 9900 | + "description": "Number of times this invite has been used", |
| 9901 | + "type": "integer", |
| 9902 | + "format": "uint64", |
| 9903 | + "minimum": 0.0 |
| 9904 | + }, |
| 9905 | + "expires": { |
| 9906 | + "description": "Timestamp at which this invite expires", |
| 9907 | + "allOf": [ |
| 9908 | + { |
| 9909 | + "$ref": "#/components/schemas/ISO8601 Timestamp" |
| 9910 | + } |
| 9911 | + ], |
| 9912 | + "nullable": true |
9874 | 9913 | } |
9875 | 9914 | } |
9876 | 9915 | }, |
|
9881 | 9920 | "_id", |
9882 | 9921 | "channel", |
9883 | 9922 | "creator", |
9884 | | - "type" |
| 9923 | + "type", |
| 9924 | + "uses" |
9885 | 9925 | ], |
9886 | 9926 | "properties": { |
9887 | 9927 | "type": { |
|
9901 | 9941 | "channel": { |
9902 | 9942 | "description": "Id of the group channel this invite points to", |
9903 | 9943 | "type": "string" |
| 9944 | + }, |
| 9945 | + "max_uses": { |
| 9946 | + "description": "Maximum number of times this invite can be used", |
| 9947 | + "type": "integer", |
| 9948 | + "format": "uint64", |
| 9949 | + "minimum": 0.0, |
| 9950 | + "nullable": true |
| 9951 | + }, |
| 9952 | + "uses": { |
| 9953 | + "description": "Number of times this invite has been used", |
| 9954 | + "type": "integer", |
| 9955 | + "format": "uint64", |
| 9956 | + "minimum": 0.0 |
| 9957 | + }, |
| 9958 | + "expires": { |
| 9959 | + "description": "Timestamp at which this invite expires", |
| 9960 | + "allOf": [ |
| 9961 | + { |
| 9962 | + "$ref": "#/components/schemas/ISO8601 Timestamp" |
| 9963 | + } |
| 9964 | + ], |
| 9965 | + "nullable": true |
9904 | 9966 | } |
9905 | 9967 | } |
9906 | 9968 | } |
9907 | 9969 | ] |
9908 | 9970 | }, |
| 9971 | + "ISO8601 Timestamp": { |
| 9972 | + "description": "ISO8601 formatted timestamp", |
| 9973 | + "type": "string", |
| 9974 | + "format": "date-time", |
| 9975 | + "example": "1970-01-01T00:00:00Z" |
| 9976 | + }, |
| 9977 | + "DataCreateInvite": { |
| 9978 | + "description": "Create Invite", |
| 9979 | + "type": "object", |
| 9980 | + "properties": { |
| 9981 | + "max_uses": { |
| 9982 | + "description": "Maximum number of times this invite can be used", |
| 9983 | + "type": "integer", |
| 9984 | + "format": "uint64", |
| 9985 | + "maximum": 100.0, |
| 9986 | + "minimum": 1.0, |
| 9987 | + "nullable": true |
| 9988 | + }, |
| 9989 | + "expires": { |
| 9990 | + "description": "Number of seconds until this invite expires", |
| 9991 | + "allOf": [ |
| 9992 | + { |
| 9993 | + "$ref": "#/components/schemas/ISO8601 Timestamp" |
| 9994 | + } |
| 9995 | + ], |
| 9996 | + "nullable": true |
| 9997 | + } |
| 9998 | + } |
| 9999 | + }, |
9909 | 10000 | "Message": { |
9910 | 10001 | "description": "Message", |
9911 | 10002 | "type": "object", |
|
10150 | 10241 | } |
10151 | 10242 | } |
10152 | 10243 | }, |
10153 | | - "ISO8601 Timestamp": { |
10154 | | - "description": "ISO8601 formatted timestamp", |
10155 | | - "type": "string", |
10156 | | - "format": "date-time", |
10157 | | - "example": "1970-01-01T00:00:00Z" |
10158 | | - }, |
10159 | 10244 | "MessageWebhook": { |
10160 | 10245 | "description": "Information about the webhook bundled with Message", |
10161 | 10246 | "type": "object", |
|
0 commit comments