Repository navigation
Expand file tree
/
Copy pathmessaging.yaml
More file actions
56 lines (56 loc) · 1.9 KB
/
Copy pathmessaging.yaml
File metadata and controls
56 lines (56 loc) · 1.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
# yaml-language-server: $schema=https://id.registrystack.org/schemas/messaging/project/project.v1alpha1.schema.json
apiVersion: id.registrystack.org/formats/messaging/project/v1alpha1
kind: MessagingProject
# The project this file names: the identity a package built from it carries.
project:
id: starter
version: "1"
# The transports this deployment sends through. The type and, for an http
# provider, its scripts under providers/<id>/ are package; each provider's
# endpoint and credentials are runtime configuration. `idempotentSubmit`
# declares that the provider drops a repeat carrying the same idempotency key.
providers:
- id: mail-relay
type: smtp
- id: sms-gateway
type: http
idempotentSubmit: true
# What a caller selects: a channel, the provider carrying it, the sender
# identity, and for SMS the most segments one message may use.
senderProfiles:
- id: transactional
channel: email
provider: mail-relay
sender: notices@example.org
- id: reminders-sms
channel: sms
provider: sms-gateway
sender: Registry
maximumSegments: 2
# Every template version the package ships, each under
# templates/<id>/<version>/. A version is a label, so quote a numeric one.
templates:
- id: appointment-reminder
version: "1"
- id: appointment-reminder-sms
version: "1"
# Who may call this deployment and what each caller may do. A client appears
# in exactly one profile.
accessProfiles:
- id: case-notices
principalClaim: sub
requiredScopes: [messaging:send]
requesterClients: [case-system]
actorKind: service
actsAs: sender
senderProfiles: [transactional, reminders-sms]
templates: [appointment-reminder, appointment-reminder-sms]
requestsPerMinute: 60
burst: 10
- id: operations
principalClaim: sub
requiredScopes: [messaging:operate]
requesterClients: [operations-console]
actsAs: operator
requestsPerMinute: 60
burst: 10