You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/reference/other/openid.md
+11-10Lines changed: 11 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -118,16 +118,17 @@ Some credential template fields may be intended for URLs which resolve to images
118
118
119
119
By default, these will display to the holders in the OIDC flow as simple text fields containing the raw URL. However, the template can be configured to display these URLs as either inline embedded images, or convenient links to download the linked data.
120
120
121
-
When creating a Template:
122
-
123
-
- Choose the `Uri` type for any Fields which are intended to contain URIs.
124
-
- Set the `trinsic/web.display_method` annotation on the Field
125
-
- If the field is intended to contain an image, use the value `inline`.
126
-
- Otherwise, use the value `download`.
127
-
- Set the `trinsic/file.content_type` annotation on the Field
128
-
- Use the value `image` if the field is intended to contain a link to an image
129
-
- Otherwise, the value should be the expected MIME Type of the data
130
-
- If you are unsure, use `application/octet-stream` as a catch-all
121
+
When creating or updating a Template:
122
+
123
+
- Choose the `URI` type for any Fields which are intended to contain URIs.
124
+
- Configure the `UriData` object on the Field
125
+
- Set the `RenderMethod` property
126
+
- If the field is intended to contain an image, use the value `INLINE_IMAGE`.
127
+
- Otherwise, use `LINK` for a clickable link, or `TEXT` to display the URI in raw form.
128
+
- Set the `MimeType` property
129
+
- Use the value `image` if the field is intended to contain a link to an image
130
+
- Otherwise, the value should be the expected MIME Type of the data
131
+
- If you are unsure, use `application/octet-stream` as a catch-all
Copy file name to clipboardExpand all lines: docs/reference/services/template-service.md
+60-13Lines changed: 60 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,23 +4,17 @@
4
4
The Template Service allows you to manage and search [Credential Templates](/learn/concepts/templates).
5
5
6
6
7
-
!!! info "Templates are optional"
8
-
Templates are designed to be a helpful abstraction over the complexities of producing valid [JSON-LD Verifiable Credentials](https://www.w3.org/TR/vc-data-model/).
9
-
10
-
You aren't required to use templates; if you produce valid JSON-LD VCs yourself, they can be issued through Trinsic.
11
-
12
7
---
13
8
14
9
## Create Template
15
10
16
-
!!! info "Field Annotations"
17
-
When defining the Fields of a Template, the `annotations` object can be used to set arbitrary key-value metadata on a Field.
11
+
Creates a new credential template.
18
12
19
-
Trinsic defines certain annotations that dictate how a credential field containing a URI will render during the verification flow.
13
+
The `name` of a template must be unique within your ecosystem, and cannot be changed -- it is used to derive the URI of the template itself.
20
14
21
-
[Click here](../../reference/other/openid.md) for more information on this use case.
15
+
The `title` and `description` parameters (for the template itself, as well as for any of its fields) should be human-readable strings. They should describe the credentials issued by the template, not the template itself (for example, a good title for a medical license template would simply be "Medical License", not "Medical License Template").
22
16
23
-
Creates a new credential template.
17
+
`field_ordering` may be used to specify the order in which fields are rendered when displaying a credential, and to categorize fields into logical sections. This is used for display only, and has no bearing on working with credentials as an issuer or verifier.
24
18
25
19
{{ proto_sample_start() }}
26
20
=== "Trinsic CLI"
@@ -31,7 +25,7 @@ Creates a new credential template.
@@ -67,14 +61,67 @@ Creates a new credential template.
67
61
68
62
---
69
63
64
+
## Update Template
65
+
66
+
Updates a template's display metadata, such as its human-readable title/description.
67
+
68
+
This call cannot be used to update templates in a way that might invalidate previously-issued credentials: fields cannot be added, removed, or renamed, but their `title` and `description` properties may be updated.
69
+
70
+
In order to leave a property unchanged (for example, if you wish to change `description` but not `title`), simply leave it unspecified (_don't_ set it to an empty string/object). This applies to fields as well: any field not specified in `fields` will remain unchanged.
0 commit comments