Directus / @directus/sdk / rest / createNotifications
Function: createNotifications() ​
createNotifications<
Schema
,TQuery
>(items
,query
?):RestCommand
<IfAny
<Schema
,Record
<string
,any
>,Merge
<MappedFunctionFields
<Schema
,UnpackList
<IfAny
<Schema
,Object
,"directus_notifications"
extends keyofSchema
?UnpackList
<...> extendsItem
? ... & ... :never
:Object
>>> extendsFF
?MapFlatFields
<UnpackList
<IfAny
<Schema
,Object
,"directus_notifications"
extends keyofSchema
?UnpackList
<...> extendsItem
? ... & ... :never
:Object
>>,FieldsWildcard
<UnpackList
<IfAny
<Schema
,Object
,"directus_notifications"
extends keyof ... ? ... extends ... ? ... : ... :Object
>>,Exclude
<UnpackList
<Mutable
<...[...]>>,PickRelationalFields
<UnpackList
<...>> extendsnever
?never
:AllKeys
<... extends ... ? ... : ...>>>,FF
extendsRecord
<string
,string
> ?FF
<FF
> :Record
<string
,string
>> :never
,PickRelationalFields
<UnpackList
<Mutable
<TQuery
["fields"
]>>> extendsnever
?never
:{ [Field in string | number | symbol]: Field extends keyof UnpackList<IfAny<Schema, Object, (...) extends (...) ? (...) : (...)>> ? Extract<UnpackList<(...)>[Field<(...)>], ItemType<Schema>> extends RelatedCollection ? IsNullable<UnpackList<(...)>[Field<(...)>], null | ((...) extends (...) ? (...) : (...)), RelatedCollection extends (...)[] ? (...) extends (...) ? (...) : (...) : ApplyNestedQueryFields<(...), (...), (...)>> : never : never }
>>[],Schema
>
Create multiple new notifications.
Type parameters ​
• Schema
• TQuery extends Query
<Schema
, DirectusNotification
<Schema
>>
Parameters ​
• items: Partial
<DirectusNotification
<Schema
>>[]
The notifications to create
• query?: TQuery
Optional return data query
Returns ​
RestCommand
<IfAny
<Schema
, Record
<string
, any
>, Merge
<MappedFunctionFields
<Schema
, UnpackList
<IfAny
<Schema
, Object
, "directus_notifications"
extends keyof Schema
? UnpackList
<...> extends Item
? ... & ... : never
: Object
>>> extends FF
? MapFlatFields
<UnpackList
<IfAny
<Schema
, Object
, "directus_notifications"
extends keyof Schema
? UnpackList
<...> extends Item
? ... & ... : never
: Object
>>, FieldsWildcard
<UnpackList
<IfAny
<Schema
, Object
, "directus_notifications"
extends keyof ... ? ... extends ... ? ... : ... : Object
>>, Exclude
<UnpackList
<Mutable
<...[...]>>, PickRelationalFields
<UnpackList
<...>> extends never
? never
: AllKeys
<... extends ... ? ... : ...>>>, FF
extends Record
<string
, string
> ? FF
<FF
> : Record
<string
, string
>> : never
, PickRelationalFields
<UnpackList
<Mutable
<TQuery
["fields"
]>>> extends never
? never
: { [Field in string | number | symbol]: Field extends keyof UnpackList<IfAny<Schema, Object, (...) extends (...) ? (...) : (...)>> ? Extract<UnpackList<(...)>[Field<(...)>], ItemType<Schema>> extends RelatedCollection ? IsNullable<UnpackList<(...)>[Field<(...)>], null | ((...) extends (...) ? (...) : (...)), RelatedCollection extends (...)[] ? (...) extends (...) ? (...) : (...) : ApplyNestedQueryFields<(...), (...), (...)>> : never : never }
>>[], Schema
>
Returns the notification object for the created notification.