@altnovatrail/contracts 0.11.0 → 0.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,145 @@
1
+ // @generated by protoc-gen-es v2.16.0 with parameter "target=js+dts,import_extension=js"
2
+ // @generated from file novatrail/api/v1/legal.proto (package novatrail.api.v1, syntax proto3)
3
+ /* eslint-disable */
4
+
5
+ // The legal texts in the contract between `app` and `api`: the privacy policy, the terms of use
6
+ // and the consents that `app` shows as its own pages, each in its current version, with its gist
7
+ // in the language of the screen. The texts are those of the legal part, `legal/` of `spec`, or of a
8
+ // self-hosted copy's operator. What each message means is the rule of contracts/README.md,
9
+ // section 15.
10
+
11
+ import type { GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv2";
12
+ import type { Message } from "@bufbuild/protobuf";
13
+
14
+ /**
15
+ * Describes the file novatrail/api/v1/legal.proto.
16
+ */
17
+ export declare const file_novatrail_api_v1_legal: GenFile;
18
+
19
+ /**
20
+ * A request for the legal texts.
21
+ *
22
+ * @generated from message novatrail.api.v1.GetLegalTextsRequest
23
+ */
24
+ export declare type GetLegalTextsRequest = Message<"novatrail.api.v1.GetLegalTextsRequest"> & {
25
+ /**
26
+ * The language of the screen that shows the texts, a well-formed tag of BCP 47, a field of the
27
+ * message and not the header `Accept-Language` (R92): the language the gists come in. Empty
28
+ * asks for English.
29
+ *
30
+ * @generated from field: string interface_language = 1;
31
+ */
32
+ interfaceLanguage: string;
33
+ };
34
+
35
+ /**
36
+ * Describes the message novatrail.api.v1.GetLegalTextsRequest.
37
+ * Use `create(GetLegalTextsRequestSchema)` to create a new message.
38
+ */
39
+ export declare const GetLegalTextsRequestSchema: GenMessage<GetLegalTextsRequest>;
40
+
41
+ /**
42
+ * The legal texts.
43
+ *
44
+ * @generated from message novatrail.api.v1.GetLegalTextsResponse
45
+ */
46
+ export declare type GetLegalTextsResponse = Message<"novatrail.api.v1.GetLegalTextsResponse"> & {
47
+ /**
48
+ * The current version of every text whose place is `app`, in the order of their IDs by code
49
+ * units. A text with no version in force has none, and is absent: the list is empty while no such
50
+ * text is in force.
51
+ *
52
+ * @generated from field: repeated novatrail.api.v1.LegalText texts = 1;
53
+ */
54
+ texts: LegalText[];
55
+ };
56
+
57
+ /**
58
+ * Describes the message novatrail.api.v1.GetLegalTextsResponse.
59
+ * Use `create(GetLegalTextsResponseSchema)` to create a new message.
60
+ */
61
+ export declare const GetLegalTextsResponseSchema: GenMessage<GetLegalTextsResponse>;
62
+
63
+ /**
64
+ * A legal text in its current version: its version in force with the highest number.
65
+ *
66
+ * @generated from message novatrail.api.v1.LegalText
67
+ */
68
+ export declare type LegalText = Message<"novatrail.api.v1.LegalText"> & {
69
+ /**
70
+ * The ID of the text in the passport: lower-case Latin letters and digits in words joined by
71
+ * hyphens, such as "privacy-policy".
72
+ *
73
+ * @generated from field: string id = 1;
74
+ */
75
+ id: string;
76
+
77
+ /**
78
+ * The number of the version, from 1 on.
79
+ *
80
+ * @generated from field: int32 version = 2;
81
+ */
82
+ version: number;
83
+
84
+ /**
85
+ * The date the author approved the version, from which it is in force, `YYYY-MM-DD`.
86
+ *
87
+ * @generated from field: string in_force_since = 3;
88
+ */
89
+ inForceSince: string;
90
+
91
+ /**
92
+ * The text of the version, in English, the one in force: Markdown, CommonMark with the tables of
93
+ * GitHub's flavour, that begins with a heading of the first level, the text's title, and holds no
94
+ * HTML, no image and no link.
95
+ *
96
+ * @generated from field: string body = 4;
97
+ */
98
+ body: string;
99
+
100
+ /**
101
+ * The gist of the version, plain text with no Markdown, of at most 1000 characters: in the
102
+ * language asked when the passport has it, found as the lookup of RFC 4647 finds it — the tag,
103
+ * then the tag cut by its last subtag, with no regard to case — and else in English.
104
+ *
105
+ * @generated from field: string summary = 5;
106
+ */
107
+ summary: string;
108
+
109
+ /**
110
+ * The language the gist is in, its tag as the passport writes it, such as "en" or "ru".
111
+ *
112
+ * @generated from field: string summary_language = 6;
113
+ */
114
+ summaryLanguage: string;
115
+ };
116
+
117
+ /**
118
+ * Describes the message novatrail.api.v1.LegalText.
119
+ * Use `create(LegalTextSchema)` to create a new message.
120
+ */
121
+ export declare const LegalTextSchema: GenMessage<LegalText>;
122
+
123
+ /**
124
+ * The legal texts that `app` shows (R130). The method goes without a token and without the ID of a
125
+ * profile, by Connect GET: the policy is read before signing in. It has the idempotency level
126
+ * `NO_SIDE_EFFECTS`, and `app` calls it with no header — no `Connect-Timeout-Ms` either, which
127
+ * would make the request not simple and send a preflight before it. It has no refusal of its own:
128
+ * a tag that is not a well-formed tag of BCP 47 gets `invalid_argument` with no `Refusal`.
129
+ *
130
+ * @generated from service novatrail.api.v1.LegalService
131
+ */
132
+ export declare const LegalService: GenService<{
133
+ /**
134
+ * The current version of every text whose place is `app`, with its body in English and its gist
135
+ * in the language asked when the passport has it, else in English.
136
+ *
137
+ * @generated from rpc novatrail.api.v1.LegalService.GetLegalTexts
138
+ */
139
+ getLegalTexts: {
140
+ methodKind: "unary";
141
+ input: typeof GetLegalTextsRequestSchema;
142
+ output: typeof GetLegalTextsResponseSchema;
143
+ },
144
+ }>;
145
+
@@ -0,0 +1,51 @@
1
+ // @generated by protoc-gen-es v2.16.0 with parameter "target=js+dts,import_extension=js"
2
+ // @generated from file novatrail/api/v1/legal.proto (package novatrail.api.v1, syntax proto3)
3
+ /* eslint-disable */
4
+
5
+ // The legal texts in the contract between `app` and `api`: the privacy policy, the terms of use
6
+ // and the consents that `app` shows as its own pages, each in its current version, with its gist
7
+ // in the language of the screen. The texts are those of the legal part, `legal/` of `spec`, or of a
8
+ // self-hosted copy's operator. What each message means is the rule of contracts/README.md,
9
+ // section 15.
10
+
11
+ import { fileDesc, messageDesc, serviceDesc } from "@bufbuild/protobuf/codegenv2";
12
+
13
+ /**
14
+ * Describes the file novatrail/api/v1/legal.proto.
15
+ */
16
+ export const file_novatrail_api_v1_legal = /*@__PURE__*/
17
+ fileDesc("Chxub3ZhdHJhaWwvYXBpL3YxL2xlZ2FsLnByb3RvEhBub3ZhdHJhaWwuYXBpLnYxIjIKFEdldExlZ2FsVGV4dHNSZXF1ZXN0EhoKEmludGVyZmFjZV9sYW5ndWFnZRgBIAEoCSJDChVHZXRMZWdhbFRleHRzUmVzcG9uc2USKgoFdGV4dHMYASADKAsyGy5ub3ZhdHJhaWwuYXBpLnYxLkxlZ2FsVGV4dCJ5CglMZWdhbFRleHQSCgoCaWQYASABKAkSDwoHdmVyc2lvbhgCIAEoBRIWCg5pbl9mb3JjZV9zaW5jZRgDIAEoCRIMCgRib2R5GAQgASgJEg8KB3N1bW1hcnkYBSABKAkSGAoQc3VtbWFyeV9sYW5ndWFnZRgGIAEoCTJ1CgxMZWdhbFNlcnZpY2USZQoNR2V0TGVnYWxUZXh0cxImLm5vdmF0cmFpbC5hcGkudjEuR2V0TGVnYWxUZXh0c1JlcXVlc3QaJy5ub3ZhdHJhaWwuYXBpLnYxLkdldExlZ2FsVGV4dHNSZXNwb25zZSIDkAIBQsMBChRjb20ubm92YXRyYWlsLmFwaS52MUIKTGVnYWxQcm90b1ABWj1naXRodWIuY29tL2FsdG5vdmF0cmFpbC9zcGVjL2NvbnRyYWN0cy9ub3ZhdHJhaWwvYXBpL3YxO2FwaXYxogIDTkFYqgIQTm92YXRyYWlsLkFwaS5WMcoCEE5vdmF0cmFpbFxBcGlcVjHiAhxOb3ZhdHJhaWxcQXBpXFYxXEdQQk1ldGFkYXRh6gISTm92YXRyYWlsOjpBcGk6OlYxYgZwcm90bzM");
18
+
19
+ /**
20
+ * Describes the message novatrail.api.v1.GetLegalTextsRequest.
21
+ * Use `create(GetLegalTextsRequestSchema)` to create a new message.
22
+ */
23
+ export const GetLegalTextsRequestSchema = /*@__PURE__*/
24
+ messageDesc(file_novatrail_api_v1_legal, 0);
25
+
26
+ /**
27
+ * Describes the message novatrail.api.v1.GetLegalTextsResponse.
28
+ * Use `create(GetLegalTextsResponseSchema)` to create a new message.
29
+ */
30
+ export const GetLegalTextsResponseSchema = /*@__PURE__*/
31
+ messageDesc(file_novatrail_api_v1_legal, 1);
32
+
33
+ /**
34
+ * Describes the message novatrail.api.v1.LegalText.
35
+ * Use `create(LegalTextSchema)` to create a new message.
36
+ */
37
+ export const LegalTextSchema = /*@__PURE__*/
38
+ messageDesc(file_novatrail_api_v1_legal, 2);
39
+
40
+ /**
41
+ * The legal texts that `app` shows (R130). The method goes without a token and without the ID of a
42
+ * profile, by Connect GET: the policy is read before signing in. It has the idempotency level
43
+ * `NO_SIDE_EFFECTS`, and `app` calls it with no header — no `Connect-Timeout-Ms` either, which
44
+ * would make the request not simple and send a preflight before it. It has no refusal of its own:
45
+ * a tag that is not a well-formed tag of BCP 47 gets `invalid_argument` with no `Refusal`.
46
+ *
47
+ * @generated from service novatrail.api.v1.LegalService
48
+ */
49
+ export const LegalService = /*@__PURE__*/
50
+ serviceDesc(file_novatrail_api_v1_legal, 0);
51
+
@@ -88,8 +88,10 @@ export declare type Sample = Message<"novatrail.eval.v1.Sample"> & {
88
88
 
89
89
  /**
90
90
  * The version of the set of texts that the samples page showed: the notice of the purpose and
91
- * the form of consent. 1 to 32 Latin letters, digits, dots and hyphens; "none" in a file that the
92
- * samples page did not write, a synthetic sample among them.
91
+ * the form of consent. 1 to 32 Latin letters, digits, dots and hyphens: from the legal part on,
92
+ * the set's ID and version joined by a hyphen, such as "child-sample-1" (legal/README.md,
93
+ * section 4); "none" in a file that the samples page did not write, a synthetic sample among
94
+ * them.
93
95
  *
94
96
  * @generated from field: string text_set_version = 8;
95
97
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@altnovatrail/contracts",
3
- "version": "0.11.0",
3
+ "version": "0.13.0",
4
4
  "description": "The code of NovaTrail's API contracts for TypeScript, which protoc-gen-es generates from their protobuf files: the messages and enums of each contract, with their descriptors, for @bufbuild/protobuf and Connect.",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -25,6 +25,10 @@
25
25
  "types": "./novatrail/api/v1/learning_pb.d.ts",
26
26
  "default": "./novatrail/api/v1/learning_pb.js"
27
27
  },
28
+ "./novatrail/api/v1/legal_pb.js": {
29
+ "types": "./novatrail/api/v1/legal_pb.d.ts",
30
+ "default": "./novatrail/api/v1/legal_pb.js"
31
+ },
28
32
  "./novatrail/api/v1/module_pb.js": {
29
33
  "types": "./novatrail/api/v1/module_pb.d.ts",
30
34
  "default": "./novatrail/api/v1/module_pb.js"