@wix/bex-utils 2.30.0 → 2.31.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.
Files changed (114) hide show
  1. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/builders.impl.d.ts +89 -0
  2. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/builders.impl.js +2249 -0
  3. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/builders.impl.js.map +1 -0
  4. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/crud/http.impl.d.ts +1 -0
  5. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/crud/http.impl.js +5 -0
  6. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/crud/http.impl.js.map +1 -0
  7. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/crud/rpc.impl.d.ts +6 -0
  8. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/crud/rpc.impl.js +24 -0
  9. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/crud/rpc.impl.js.map +1 -0
  10. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/http.impl.d.ts +180 -0
  11. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/http.impl.js +971 -0
  12. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/http.impl.js.map +1 -0
  13. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/meta.impl.d.ts +30 -0
  14. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/meta.impl.js +385 -0
  15. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/meta.impl.js.map +1 -0
  16. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/proto/client/proto-generated.d.ts +10010 -0
  17. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/proto/client/proto-generated.js +2 -0
  18. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/proto/proto-generated.d.ts +5002 -0
  19. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/proto/proto-generated.js +78224 -0
  20. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/proto/server/proto-generated.d.ts +9973 -0
  21. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/proto/server/proto-generated.js +2 -0
  22. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/rpc.impl.d.ts +189 -0
  23. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/rpc.impl.js +431 -0
  24. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/rpc.impl.js.map +1 -0
  25. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/types.impl.d.ts +1387 -0
  26. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/types.impl.js +117 -0
  27. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/cjs/types.impl.js.map +1 -0
  28. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/builders.impl.d.ts +89 -0
  29. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/builders.impl.js +2145 -0
  30. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/builders.impl.js.map +1 -0
  31. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/crud/http.impl.d.ts +1 -0
  32. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/crud/http.impl.js +2 -0
  33. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/crud/http.impl.js.map +1 -0
  34. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/crud/rpc.impl.d.ts +6 -0
  35. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/crud/rpc.impl.js +19 -0
  36. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/crud/rpc.impl.js.map +1 -0
  37. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/http.impl.d.ts +180 -0
  38. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/http.impl.js +949 -0
  39. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/http.impl.js.map +1 -0
  40. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/meta.impl.d.ts +30 -0
  41. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/meta.impl.js +344 -0
  42. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/meta.impl.js.map +1 -0
  43. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/rpc.impl.d.ts +189 -0
  44. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/rpc.impl.js +390 -0
  45. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/rpc.impl.js.map +1 -0
  46. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/types.impl.d.ts +1387 -0
  47. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/types.impl.js +114 -0
  48. package/@wix/ambassador-media-site-media-v1-file-descriptor/build/es/types.impl.js.map +1 -0
  49. package/@wix/ambassador-media-site-media-v1-file-descriptor/builders/package.json +7 -0
  50. package/@wix/ambassador-media-site-media-v1-file-descriptor/crud/http/package.json +7 -0
  51. package/@wix/ambassador-media-site-media-v1-file-descriptor/crud/rpc/package.json +6 -0
  52. package/@wix/ambassador-media-site-media-v1-file-descriptor/http/package.json +7 -0
  53. package/@wix/ambassador-media-site-media-v1-file-descriptor/meta/package.json +7 -0
  54. package/@wix/ambassador-media-site-media-v1-file-descriptor/package.json +53 -0
  55. package/@wix/ambassador-media-site-media-v1-file-descriptor/rpc/package.json +6 -0
  56. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/media_manager/v1/media_manager_entity.proto +17 -0
  57. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/media_manager/v1/media_manager_service.proto +121 -0
  58. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/media_manager/v1/search_result.proto +17 -0
  59. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/media_manager/v1/search_service.proto +76 -0
  60. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/media_quota_api.proto +159 -0
  61. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/upstream/wix/common/identification.proto +41 -0
  62. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/upstream/wix/common/media.proto +242 -0
  63. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/upstream/wix/common/paging.proto +121 -0
  64. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/audio_v2.proto +31 -0
  65. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/content_disposition.proto +11 -0
  66. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/download_url.proto +12 -0
  67. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/error_code.proto +49 -0
  68. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/errors.proto +41 -0
  69. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/file_descriptor.proto +140 -0
  70. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/files_service.proto +1030 -0
  71. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/folder.proto +48 -0
  72. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/folders_service.proto +367 -0
  73. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/identity_info.proto +13 -0
  74. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/image_media.proto +84 -0
  75. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/media_type.proto +15 -0
  76. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/namespace.proto +21 -0
  77. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/operation_status.proto +27 -0
  78. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/other_media.proto +22 -0
  79. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/root_folders.proto +12 -0
  80. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/storage_info.proto +24 -0
  81. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/storage_service.proto +179 -0
  82. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/com/wix/media/site_media/v1/upload_protocol.proto +9 -0
  83. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/action_payload.proto +33 -0
  84. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/annotations.proto +393 -0
  85. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/api_errors.proto +117 -0
  86. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/callback.proto +156 -0
  87. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/context.proto +19 -0
  88. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/entity.proto +122 -0
  89. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/errors.proto +119 -0
  90. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/idempotency.proto +25 -0
  91. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/permissions.proto +40 -0
  92. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/sla.proto +24 -0
  93. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/subscription.proto +32 -0
  94. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/api/validations.proto +137 -0
  95. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/address.proto +148 -0
  96. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/bulk.proto +53 -0
  97. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/identification.proto +40 -0
  98. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/image.proto +8 -0
  99. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/media.proto +236 -0
  100. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/money.proto +32 -0
  101. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/pageurl.proto +32 -0
  102. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/paging.proto +121 -0
  103. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/query.proto +795 -0
  104. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/sorting.proto +36 -0
  105. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/spi.proto +85 -0
  106. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/tags.proto +55 -0
  107. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/common/wixlink.proto +201 -0
  108. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/graphql/definitions.proto +13 -0
  109. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/http/field_mask.proto +46 -0
  110. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/sdk/definitions.proto +191 -0
  111. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/spi/definitions.proto +186 -0
  112. package/@wix/ambassador-media-site-media-v1-file-descriptor/src/main/proto/wix/spi/http_error_status.proto +24 -0
  113. package/@wix/ambassador-media-site-media-v1-file-descriptor/types/package.json +7 -0
  114. package/package.json +3 -2
@@ -0,0 +1,137 @@
1
+ syntax = "proto2";
2
+
3
+ package wix.api;
4
+
5
+ import "wix/api/api_errors.proto";
6
+ import "google/protobuf/descriptor.proto";
7
+
8
+ option java_multiple_files = true;
9
+ option java_outer_classname = "ValidationsProto";
10
+ option java_package = "com.wix.api";
11
+
12
+ /**
13
+ * Annotation for field validation rules
14
+ * example usage:
15
+ * import "wix/api/validations.proto";
16
+ *
17
+ * message User {
18
+ * string id = 1 [(wix.api.readOnly)=true, (wix.api.format)=GUID];
19
+ * double age = 2 [(wix.api.max)=120, (wix.api.min)=0];
20
+ * string email = 3 [(wix.api.format)=EMAIL];
21
+ * string username = 4 [(wix.api.minLength)=3];
22
+ * string phone = 5 [(wix.api.format)=PHONE];
23
+ * }
24
+ *
25
+ * message Invoice {
26
+ * string id = 1 [(wix.api.readOnly)=true, (wix.api.format)=GUID];
27
+ * string amount_paid = 2 [(wix.api.decimalValue) = { gte: "0.01" lt: "10" maxScale: 2 }];
28
+ * }
29
+ **/
30
+ extend google.protobuf.FieldOptions {
31
+ // max possible value
32
+ optional double max = 50201;
33
+ // min possible value
34
+ optional double min = 50202;
35
+ // max length for strings
36
+ optional int32 maxLength = 50203;
37
+ // min length for strings
38
+ optional int32 minLength = 50204;
39
+ // max size for repeated field, map
40
+ optional int32 maxSize = 50209;
41
+ // min size for repeated field, map
42
+ optional int32 minSize = 50210;
43
+ // common known formats like email, URI, etc.
44
+ optional Format format = 50205;
45
+ // indicates this field cannot be set by the client. E.g. Id field assigned by the server
46
+ optional bool readOnly = 50208;
47
+ // indicates this field can be set by the client, but can never be changed or updated
48
+ optional bool immutable = 50212;
49
+ // indicates this field is input-only, it will NOT be returned in output response
50
+ optional bool writeOnly = 50154;
51
+ // decimal value format
52
+ optional DecimalValueOptions decimalValue = 50211;
53
+ // declare custom field validation for all methods
54
+ optional CustomValidationError custom_validation = 50214;
55
+ }
56
+
57
+ /**
58
+ * Decimal value validation rules.
59
+ * Based on java.math.BigDecimal, implies (wix.api.format) = DECIMAL_VALUE
60
+ */
61
+ message DecimalValueOptions {
62
+ optional string lte = 1; // less than or equal
63
+ optional string gte = 2; // greater than or equal
64
+ optional string lt = 3; // less than
65
+ optional string gt = 4; // greater than
66
+ optional int32 maxScale = 5; // max number of fractional digits
67
+ }
68
+
69
+ /**
70
+ * Annotation for method validation rules
71
+ * example usage:
72
+ * import "wix/api/validations.proto";
73
+ * service Bloop {
74
+ * rpc Create (CreateBloopRequest) returns (CreateBloopResponse) {
75
+ * option (wix.api.required) = "CreateBloopRequest.Bloop.name";
76
+ * }
77
+ * }
78
+ **/
79
+ extend google.protobuf.MethodOptions {
80
+ // Specify which fields are required in this method.
81
+ // Annotating a nested field as `required` does not imply that the whole path to that field is required, eg.
82
+ // `option (wix.api.required) = "person.pet.name";` means that if a `person` has a `pet`, then the `pet` must have
83
+ // a `name` set; it does not mean that `person` or `person.pet` themselves are required - these fields should be
84
+ // annotated individually if needed.
85
+ // This option can be repeated multiple times to specify multiple fields.
86
+ // example use:
87
+ // option (wix.api.required) = "userId";
88
+ // option (wix.api.required) = "userName";
89
+ repeated string required = 50200;
90
+ // Specify list of `immutable` fields which can be writable in this method.
91
+ // Most common in Create methods
92
+ // Only `immutable` AND NOT `readOnly` fields are allowed to be referenced via this annotation
93
+ // example use:
94
+ // option (wix.api.writable) = "id"; // user-generated id is enabled
95
+ repeated string writable = 50213;
96
+
97
+ }
98
+
99
+ extend google.protobuf.OneofOptions {
100
+ // name of the enum field that must be aligned with this oneof (AIP 7015)
101
+ // ADR 038: Linking oneOf with Enum: https://github.com/wix-private/server-infra/blob/master/framework/docs/adr/adr-038-aligned-with-enum.md
102
+ optional AlignedWithEnum aligned_with_enum = 50800;
103
+ }
104
+
105
+ message AlignedWithEnum {
106
+ required string field = 1;
107
+ // defaults to _options if not specified
108
+ optional string suffix = 2;
109
+ }
110
+
111
+ enum Format {
112
+ EMAIL = 0;
113
+ HOSTNAME = 1;
114
+ IPV4 = 2;
115
+ IPV6 = 3;
116
+ URI = 4;
117
+ WEB_URL = 5; // HTTP or HTTPS
118
+ PHONE = 7;
119
+ CREDIT_CARD = 8;
120
+ GUID = 9;
121
+ COUNTRY = 10; // 2 letters ISO-3166-1
122
+ LANGUAGE = 11; // 2 letters ISO-639-1
123
+ /*
124
+ Use this on string or stringValue types to validate the format of that field is same as a decimal value.
125
+ This will ensure keeping the precision of decimal value, such as when passing monetary values.
126
+ */
127
+ DECIMAL_VALUE = 12;
128
+ CURRENCY = 13; // 3 letters - all available currencies
129
+ LANGUAGE_TAG = 14; // IETF BCP 47 language tag (e.g. en-US)
130
+ COLOR_HEX = 15; // hex color format as defined by the MDN https://developer.mozilla.org/en-US/docs/Web/CSS/hex-color
131
+ LOCAL_DATE = 16; // ISO-8601 extended local date format (YYYY-MM-DD)
132
+ LOCAL_TIME = 17; // ISO-8601 extended local time format (hh:mm[:ss][.sss])
133
+ LOCAL_DATE_TIME = 18; // ISO-8601 extended local date-time format (YYYY-MM-DDThh:mm[:ss][.sss])
134
+ URL_SLUG = 19;
135
+ SYSTEM_SLUG = 20;
136
+ SECURE_WEB_URL = 21; // HTTPS only
137
+ }
@@ -0,0 +1,148 @@
1
+ syntax = "proto3";
2
+
3
+ package wix.common;
4
+
5
+ option java_multiple_files = true;
6
+ option java_package = "com.wix.common";
7
+
8
+ import "google/protobuf/wrappers.proto";
9
+ import "wix/api/annotations.proto";
10
+ import "wix/api/validations.proto";
11
+
12
+ // A common address format to use if you plan to store addresses in your service
13
+
14
+ // Physical address
15
+ message Address {
16
+ option (.wix.api.decomposition_minimum_fields) = {
17
+ field: "country"
18
+ field: "subdivision"
19
+ field: "city"
20
+ field: "postal_code"
21
+ field: "street_address"
22
+ field: "formatted_address"
23
+ };
24
+ option (.wix.api.decomposition_minimum_fields) = {
25
+ field: "country"
26
+ field: "subdivision"
27
+ field: "city"
28
+ field: "postal_code"
29
+ field: "address_line"
30
+ field: "address_line_2"
31
+ field: "formatted_address"
32
+ };
33
+ google.protobuf.StringValue country = 1 [(.wix.api.format) = COUNTRY]; // Country code.
34
+ google.protobuf.StringValue subdivision = 2; // Subdivision shorthand. Usually, a short code (2 or 3 letters) that represents a state, region, prefecture, or province. e.g. NY
35
+ google.protobuf.StringValue subdivision_iso_3166_2 = 14 [(.wix.api.maxLength) = 20, (.wix.api.field_exposure) = PRIVATE]; // Subdivision. Usually a state, region, prefecture, or province code, according to [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2), e.g. US-NY
36
+ google.protobuf.StringValue city = 3 [(.wix.api.pii) = true]; // City name.
37
+ google.protobuf.StringValue postal_code = 4 [(.wix.api.pii) = true]; // Zip/postal code.
38
+ oneof street {
39
+ StreetAddress street_address = 5; // Street name and number.
40
+ google.protobuf.StringValue address_line = 6 [(.wix.api.pii) = true]; // Main address line, usually street and number as free text.
41
+ }
42
+ google.protobuf.StringValue address_line_2 = 7 [(.wix.api.pii) = true]; // Free text providing more detailed address info. Usually contains Apt, Suite, and Floor.
43
+
44
+ google.protobuf.StringValue formatted_address = 8 [(.wix.api.pii) = true, (.wix.api.field_exposure) = PRIVATE]; // A string containing the full address of this location.
45
+ google.protobuf.StringValue hint = 9 [(.wix.api.pii) = true, (.wix.api.field_exposure) = PRIVATE]; // Free text to help find the address.
46
+ AddressLocation geocode = 10 [(.wix.api.field_exposure) = PRIVATE]; // Coordinates of the physical address.
47
+ google.protobuf.StringValue country_fullname = 11 [(.wix.api.pii) = false, (.wix.api.field_exposure) = PRIVATE]; // Country full name.
48
+ google.protobuf.StringValue subdivision_fullname = 13 [(.wix.api.pii) = false, (.wix.api.field_exposure) = PRIVATE]; // Subdivision full name.
49
+ repeated Subdivision subdivisions = 12 [(.wix.api.field_exposure) = PRIVATE, (.wix.api.maxSize) = 6]; // Multi-level subdivisions from top to bottom.
50
+ }
51
+
52
+ message Subdivision {
53
+ enum SubdivisionType {
54
+ UNKNOWN_SUBDIVISION_TYPE = 0;
55
+ ADMINISTRATIVE_AREA_LEVEL_1 = 1; // State
56
+ ADMINISTRATIVE_AREA_LEVEL_2 = 2; // County
57
+ ADMINISTRATIVE_AREA_LEVEL_3 = 3; // City/town
58
+ ADMINISTRATIVE_AREA_LEVEL_4 = 4; // Neighborhood/quarter
59
+ ADMINISTRATIVE_AREA_LEVEL_5 = 5; // Street/block
60
+ COUNTRY = 6; // ADMINISTRATIVE_AREA_LEVEL_0. Indicates the national political entity, and is typically the highest order type returned by the Geocoder.
61
+ }
62
+
63
+ // Subdivision Concordance values
64
+ message StandardDetails {
65
+ google.protobuf.StringValue iso_3166_2 = 1 [(.wix.api.maxLength) = 20]; // subdivision iso-3166-2 code according to [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2). e.g. US-NY, GB-SCT, NO-30
66
+ }
67
+
68
+ option (.wix.api.decomposition_minimum_fields) = {
69
+ field: "code"
70
+ };
71
+ string code = 1; // Short subdivision code.
72
+ string name = 2; // Subdivision full name.
73
+ SubdivisionType type = 3 [(.wix.api.field_exposure) = PRIVATE]; // Subdivision level
74
+ google.protobuf.StringValue type_info = 4 [(.wix.api.field_exposure) = PRIVATE]; // Free text description of subdivision type.
75
+ StandardDetails standard_details = 5 [(.wix.api.field_exposure) = PRIVATE]; // Standard organizations details (e.g. ISO).
76
+ }
77
+
78
+ message StreetAddress {
79
+ option (.wix.api.decomposition_minimum_fields) = {
80
+ field: "number"
81
+ field: "name"
82
+ };
83
+ string number = 1 [(.wix.api.pii) = true]; // Street number.
84
+ string name = 2 [(.wix.api.pii) = true]; // Street name.
85
+ string apt = 3 [(.wix.api.pii) = true, (.wix.api.field_exposure) = PRIVATE]; // Apartment number.
86
+ google.protobuf.StringValue formatted_address_line = 4 [(.wix.api.pii) = true, (.wix.api.field_exposure) = PRIVATE]; // Optional address line 1
87
+ }
88
+
89
+ //Contact details for the address
90
+ message AddressContactDetails {
91
+ option (.wix.api.decomposition_minimum_fields) = {
92
+ field: "full_name"
93
+ };
94
+ google.protobuf.StringValue full_name = 1 [(.wix.api.pii) = true]; // Contact's full name.
95
+ google.protobuf.StringValue phone = 2 [(.wix.api.pii) = true, (.wix.api.format) = PHONE]; // Contact's phone number.
96
+ google.protobuf.StringValue company = 3; // Contact's company name.
97
+ google.protobuf.StringValue email = 4 [(.wix.api.pii) = true, (.wix.api.format) = EMAIL]; // Email associated with the address.
98
+ }
99
+
100
+ //Full contact details for an address
101
+ message FullAddressContactDetails {
102
+ option (.wix.api.decomposition_minimum_fields) = {
103
+ field: "first_name"
104
+ field: "last_name"
105
+ };
106
+ option (.wix.api.decomposition_minimum_fields) = {
107
+ field: "full_name"
108
+ };
109
+ google.protobuf.StringValue first_name = 1 [(.wix.api.pii) = true]; // Contact's first name.
110
+ google.protobuf.StringValue last_name = 2 [(.wix.api.pii) = true]; // Contact's last name.
111
+ google.protobuf.StringValue full_name = 8 [(.wix.api.pii) = true, (.wix.api.field_exposure) = PRIVATE]; // Contact's full name.
112
+ google.protobuf.StringValue phone = 3 [(.wix.api.pii) = true, (.wix.api.format) = PHONE]; // Contact's phone number.
113
+ google.protobuf.StringValue company = 4; // Contact's company name.
114
+ google.protobuf.StringValue email = 5 [(.wix.api.pii) = true, (.wix.api.format) = EMAIL]; // Email associated with the address.
115
+ VatId vat_id = 7; // Tax info. Currently usable only in Brazil.
116
+ }
117
+
118
+ message VatId {
119
+ option (.wix.api.decomposition_minimum_fields) = {
120
+ field: "id"
121
+ field: "type"
122
+ };
123
+ string id = 1 [(.wix.api.pii) = true]; // Customer's tax ID.
124
+ /*
125
+ Tax type.
126
+
127
+ Supported values:
128
+ + `CPF`: for individual tax payers
129
+ + `CNPJ`: for corporations
130
+ */
131
+ VatType type = 2;
132
+ }
133
+
134
+ // tax info types
135
+ enum VatType {
136
+ UNSPECIFIED = 0;
137
+ CPF = 1; // CPF - for individual tax payers.
138
+ CNPJ = 2; // CNPJ - for corporations
139
+ }
140
+
141
+ message AddressLocation {
142
+ option (.wix.api.decomposition_minimum_fields) = {
143
+ field: "latitude"
144
+ field: "longitude"
145
+ };
146
+ google.protobuf.DoubleValue latitude = 1 [(.wix.api.pii) = true]; // Address latitude.
147
+ google.protobuf.DoubleValue longitude = 2 [(.wix.api.pii) = true]; // Address longitude.
148
+ }
@@ -0,0 +1,53 @@
1
+ syntax = "proto3";
2
+
3
+ package wix.common;
4
+
5
+ option java_multiple_files = true;
6
+ option java_package = "com.wix.common";
7
+
8
+ import "google/protobuf/wrappers.proto";
9
+ import "wix/api/annotations.proto";
10
+ import "wix/api/errors.proto";
11
+
12
+ message BulkActionMetadata {
13
+ // Number of items that were successfully processed.
14
+ int32 total_successes = 1;
15
+ // Number of items that couldn't be processed.
16
+ int32 total_failures = 2;
17
+ // Number of failures without details because detailed failure threshold was exceeded.
18
+ int32 undetailed_failures = 3;
19
+ }
20
+
21
+ message ItemMetadata {
22
+ // Item ID. Should always be available, unless it's impossible (for example, when failing to create an item).
23
+ google.protobuf.StringValue id = 1;
24
+ // Index of the item within the request array. Allows for correlation between request and response items.
25
+ int32 original_index = 2;
26
+ // Whether the requested action was successful for this item. When `false`, the `error` field is populated.
27
+ bool success = 3;
28
+ // Details about the error in case of failure.
29
+ .wix.api.ApplicationError error = 4;
30
+ }
31
+
32
+ enum BulkActionType {
33
+ UNKNOWN_ACTION_TYPE = 0;
34
+ INSERT = 1;
35
+ UPDATE = 2;
36
+ DELETE = 3;
37
+ }
38
+
39
+ /*
40
+
41
+ Example for using it in your service:
42
+
43
+ message BulkOrderResult {
44
+ ItemMetadata item_metadata = 1;
45
+ Order item = 2;
46
+ }
47
+
48
+ message BulkArchiveOrdersResponse {
49
+ repeated BulkOrderResult results = 1;
50
+ BulkActionMetadata bulk_action_metadata = 2;
51
+ }
52
+
53
+ */
@@ -0,0 +1,40 @@
1
+ syntax = "proto3";
2
+
3
+ package wix.common;
4
+
5
+ option java_multiple_files = true;
6
+ option java_package = "com.wix.common";
7
+
8
+ import "google/protobuf/wrappers.proto";
9
+ import "wix/api/validations.proto";
10
+ import "wix/api/annotations.proto";
11
+
12
+ message IdentificationData {
13
+ option (.wix.api.decomposition_minimum_fields) = {
14
+ field: "identity_type"
15
+ field: "anonymous_visitor_id"
16
+ field: "member_id"
17
+ field: "wix_user_id"
18
+ field: "app_id"
19
+ };
20
+ enum IdentityType {
21
+ UNKNOWN = 0;
22
+ ANONYMOUS_VISITOR = 1;
23
+ MEMBER = 2;
24
+ WIX_USER = 3;
25
+ APP = 4;
26
+ }
27
+ // ID of of a contact in the site's [CRM by Ascend](https://www.wix.com/ascend/crm) system.
28
+ google.protobuf.StringValue contact_id = 1 [(.wix.api.format) = GUID, (.wix.api.referenced_entity) = "wix.contacts.v4.contact"];
29
+ IdentityType identity_type = 6 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
30
+ oneof id {
31
+ // ID of a site visitor that has not logged in to the site.
32
+ string anonymous_visitor_id = 2 [(.wix.api.format) = GUID];
33
+ // ID of a site visitor that has logged in to the site.
34
+ string member_id = 3 [(.wix.api.format) = GUID, (.wix.api.referenced_entity) = "wix.members.v1.member"];
35
+ // ID of a Wix user (site owner, contributor, etc.).
36
+ string wix_user_id = 4 [(.wix.api.format) = GUID];
37
+ // ID of an app.
38
+ string app_id = 5 [(.wix.api.format) = GUID];
39
+ }
40
+ }
@@ -0,0 +1,8 @@
1
+ syntax = "proto3";
2
+
3
+ package wix.common;
4
+
5
+ option java_multiple_files = true;
6
+ option java_package = "com.wix.common";
7
+
8
+ //Moved to media.proto - please update your references
@@ -0,0 +1,236 @@
1
+ syntax = "proto3";
2
+
3
+ package wix.common;
4
+
5
+ option java_multiple_files = true;
6
+ option java_package = "com.wix.common";
7
+
8
+ import "wix/api/annotations.proto";
9
+ import "wix/common/image.proto";
10
+ import "google/protobuf/wrappers.proto";
11
+ import "google/protobuf/timestamp.proto";
12
+ import "wix/api/validations.proto";
13
+
14
+ message Image {
15
+ option (.wix.api.decomposition_minimum_fields) = {
16
+ field: "id"
17
+ field: "height"
18
+ field: "width"
19
+ };
20
+ // WixMedia image ID.
21
+ string id = 1;
22
+ // Image URL.
23
+ string url = 2;
24
+ // Original image height.
25
+ int32 height = 3 [(.wix.api.readOnly) = true];
26
+ // Original image width.
27
+ int32 width = 4 [(.wix.api.readOnly) = true];
28
+ // Image alt text.
29
+ google.protobuf.StringValue alt_text = 5;
30
+ // Image URL expiration date (when relevant).
31
+ google.protobuf.Timestamp url_expiration_date = 6 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
32
+ // Image filename.
33
+ google.protobuf.StringValue filename = 7 [(.wix.api.readOnly) = true];
34
+ // Image size in bytes.
35
+ google.protobuf.StringValue size_in_bytes = 8 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE, (.wix.api.format) = DECIMAL_VALUE];
36
+ }
37
+
38
+ // Deprecated - use VideoV2
39
+ message Video {
40
+ option deprecated = true;
41
+ option (.wix.api.decomposition_minimum_fields) = {
42
+ field: "id"
43
+ field: "url"
44
+ field: "height"
45
+ field: "width"
46
+ };
47
+ // WixMedia ID
48
+ string id = 1;
49
+ // URL of video
50
+ string url = 2;
51
+ // Original image height
52
+ int32 height = 3 [(.wix.api.readOnly) = true];
53
+ // Original image width
54
+ int32 width = 4 [(.wix.api.readOnly) = true];
55
+ // Video poster
56
+ Image thumbnail = 5;
57
+ }
58
+
59
+ message VideoV2 {
60
+ option (.wix.api.decomposition_minimum_fields) = {
61
+ field: "id"
62
+ field: "resolutions"
63
+ };
64
+ // WixMedia ID.
65
+ string id = 1;
66
+ // Original video URL.
67
+ string url = 4 [(.wix.api.field_exposure) = PRIVATE];
68
+ // Available resolutions for the video, starting with the optimal resolution.
69
+ repeated VideoResolution resolutions = 2 [(.wix.api.readOnly) = true, (.wix.api.maxSize) = 100];
70
+ // Video filename.
71
+ google.protobuf.StringValue filename = 3 [(.wix.api.readOnly) = true];
72
+ // Video posters.
73
+ repeated Image posters = 5 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
74
+ // Original video size in bytes.
75
+ google.protobuf.StringValue size_in_bytes = 6 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE, (.wix.api.format) = DECIMAL_VALUE];
76
+ // Video URL expiration date (when relevant).
77
+ google.protobuf.Timestamp url_expiration_date = 7 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
78
+ // Original video duration in milliseconds.
79
+ google.protobuf.Int32Value duration_in_milliseconds = 8 [(.wix.api.field_exposure) = PRIVATE, (.wix.api.readOnly) = true, (.wix.api.min) = 0];
80
+ // A short title for the video. will be used for SEO purposes.
81
+ google.protobuf.StringValue title = 9 [(wix.api.maxLength) = 300, (.wix.api.field_exposure) = PRIVATE];
82
+ // A long description for the video. will be used for SEO purposes.
83
+ google.protobuf.StringValue description = 10 [(wix.api.maxLength) = 2000, (.wix.api.field_exposure) = PRIVATE];
84
+ }
85
+
86
+ message VideoResolution {
87
+ option (.wix.api.decomposition_minimum_fields) = {
88
+ field: "url"
89
+ field: "height"
90
+ field: "width"
91
+ field: "poster"
92
+ field: "format"
93
+ };
94
+ // Video URL.
95
+ string url = 2;
96
+ // Video height.
97
+ int32 height = 3;
98
+ // Video width.
99
+ int32 width = 4;
100
+ // Deprecated. Use the `posters` property in the parent entity instead.
101
+ Image poster = 5 [(.wix.api.field_exposure) = PRIVATE, deprecated = true];
102
+ // Video format for example, mp4, hls.
103
+ string format = 6;
104
+ // Deprecated. Use the `urlExpirationDate` property in the parent entity instead.
105
+ google.protobuf.Timestamp url_expiration_date = 7 [(.wix.api.field_exposure) = PRIVATE, deprecated = true];
106
+ // Deprecated. Use the `sizeInBytes` property in the parent entity instead. Size cannot be provided per resolution.
107
+ google.protobuf.StringValue size_in_bytes = 8 [(.wix.api.field_exposure) = PRIVATE, (.wix.api.format) = DECIMAL_VALUE, deprecated = true];
108
+ // Video quality. For example: 480p, 720p.
109
+ google.protobuf.StringValue quality = 9 [(.wix.api.field_exposure) = PRIVATE];
110
+ // Video filename.
111
+ google.protobuf.StringValue filename = 10 [(.wix.api.field_exposure) = PRIVATE];
112
+ // Video duration in seconds.
113
+ google.protobuf.Int32Value duration_in_seconds = 11 [(.wix.api.field_exposure) = PRIVATE, (.wix.api.readOnly) = true, (.wix.api.min) = 0, (.wix.api.field_deprecated) = {
114
+ replaced_by: "duration_in_milliseconds"
115
+ target_removal_date: "2024-08-01"
116
+ }];
117
+ // Video duration in milliseconds.
118
+ google.protobuf.Int32Value duration_in_milliseconds = 12 [(.wix.api.field_exposure) = PRIVATE, (.wix.api.readOnly) = true, (.wix.api.min) = 0];
119
+
120
+ // When true, this is a protected asset, and calling the URL will return a 403 error.
121
+ // In order to access private assets, make a request to:
122
+ // `GenerateFileDownloadUrl` with the WixMedia id and specify the asset_key in the request
123
+ google.protobuf.BoolValue private = 30 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
124
+ // Key to identify the video resolution's relationship to the original media in WixMedia.
125
+ // Can be used to request a download for the specific video resolution.
126
+ // For example: 480p.mp4, 720p.mp4, 1080p.mp4, trailer-720p.mp4, clip-720p.mp4
127
+ google.protobuf.StringValue asset_key = 31 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
128
+ }
129
+
130
+ message Audio {
131
+ option (.wix.api.decomposition_minimum_fields) = {
132
+ field: "id"
133
+ field: "url"
134
+ };
135
+ // WixMedia ID.
136
+ string id = 1;
137
+ // Audio URL.
138
+ string url = 2;
139
+ // Audio URL expiration date (when relevant).
140
+ google.protobuf.Timestamp url_expiration_date = 3 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
141
+ // Audio size in bytes.
142
+ google.protobuf.StringValue size_in_bytes = 4 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE, (.wix.api.format) = DECIMAL_VALUE];
143
+ // Audio filename.
144
+ google.protobuf.StringValue filename = 5 [(.wix.api.readOnly) = true];
145
+ // Audio duration in milliseconds.
146
+ google.protobuf.Int32Value duration = 6 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE, (.wix.api.min) = 0];
147
+
148
+ // When true, this is a protected asset, and calling the URL will return a 403 error.
149
+ // In order to access private assets, make a request to:
150
+ // `GenerateFileDownloadUrl` with the WixMedia id and specify the asset_key in the request
151
+ google.protobuf.BoolValue private = 30 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
152
+ // Key to identify the object relationship to the original media in WixMedia.
153
+ // Can be used to request a download for the specific asset.
154
+ // For example: 128-30kbs.mp3, 320kbs.mp3, 128kbs.mp3
155
+ google.protobuf.StringValue asset_key = 31 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
156
+ // Audio format.
157
+ google.protobuf.StringValue format = 32 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
158
+ // Audio quality.
159
+ google.protobuf.StringValue quality = 33 [(.wix.api.readOnly) = true, (.wix.api.field_exposure) = PRIVATE];
160
+ }
161
+
162
+ message Document {
163
+ option (.wix.api.decomposition_minimum_fields) = {
164
+ field: "id"
165
+ field: "url"
166
+ };
167
+ // WixMedia ID.
168
+ string id = 1;
169
+ // Document URL.
170
+ string url = 2;
171
+ // Document URL expiration date (when relevant).
172
+ google.protobuf.Timestamp url_expiration_date = 3 [(.wix.api.field_exposure) = PRIVATE];
173
+ // Document size in bytes.
174
+ google.protobuf.StringValue size_in_bytes = 4 [(.wix.api.field_exposure) = PRIVATE, (.wix.api.format) = DECIMAL_VALUE];
175
+ // Document filename.
176
+ google.protobuf.StringValue filename = 5;
177
+ }
178
+
179
+ message Model3D {
180
+ option (.wix.api.decomposition_minimum_fields) = {
181
+ field: "id"
182
+ };
183
+ // WixMedia 3D ID.
184
+ string id = 1;
185
+ // 3D URL.
186
+ string url = 2;
187
+ // 3D thumbnail Image
188
+ Image thumbnail = 3;
189
+ // 3D alt text.
190
+ google.protobuf.StringValue alt_text = 5;
191
+ // 3D URL expiration date (when relevant).
192
+ google.protobuf.Timestamp url_expiration_date = 6 [(.wix.api.readOnly) = true];
193
+ // 3D filename.
194
+ google.protobuf.StringValue filename = 7 [(.wix.api.readOnly) = true];
195
+ // 3D size in bytes.
196
+ google.protobuf.StringValue size_in_bytes = 8 [(.wix.api.readOnly) = true, (.wix.api.format) = DECIMAL_VALUE];
197
+ }
198
+
199
+
200
+ message Archive {
201
+ option (.wix.api.decomposition_minimum_fields) = {
202
+ field: "id"
203
+ };
204
+ // WixMedia ID.
205
+ string id = 1;
206
+ // Archive URL.
207
+ string url = 2;
208
+ // Archive URL expiration date (when relevant).
209
+ google.protobuf.Timestamp url_expiration_date = 3 [(.wix.api.readOnly) = true];
210
+ // Archive size in bytes.
211
+ google.protobuf.StringValue size_in_bytes = 4 [(.wix.api.format) = DECIMAL_VALUE];
212
+ // Archive filename.
213
+ google.protobuf.StringValue filename = 5;
214
+ }
215
+
216
+
217
+
218
+
219
+ // Deprecated - Copy this message into your service, do not reference it
220
+ message MediaItem {
221
+ option deprecated = true;
222
+ option (.wix.api.decomposition_minimum_fields) = {
223
+ field: "image"
224
+ };
225
+ option (.wix.api.decomposition_minimum_fields) = {
226
+ field: "video"
227
+ };
228
+ option (.wix.api.decomposition_minimum_fields) = {
229
+ field: "document"
230
+ };
231
+ oneof media {
232
+ Image image = 1; // WixMedia image
233
+ Video video = 2; // WixMedia video
234
+ Document document = 3; // WixMedia document
235
+ }
236
+ }
@@ -0,0 +1,32 @@
1
+ syntax = "proto3";
2
+
3
+ package wix.common;
4
+
5
+ option java_multiple_files = true;
6
+ option java_package = "com.wix.common";
7
+
8
+ import "wix/api/annotations.proto";
9
+ import "wix/api/validations.proto";
10
+ import "google/protobuf/wrappers.proto";
11
+
12
+ // Common money formats.
13
+
14
+ // Money.
15
+ // Default format to use. Sufficiently compliant with majority of standards: w3c, ISO 4217, ISO 20022, ISO 8583:2003.
16
+ message Money {
17
+ option (.wix.api.decomposition_minimum_fields) = {
18
+ field: "value"
19
+ field: "currency"
20
+ };
21
+ // For special cases, one may use just a value without currency to represent money. But:
22
+ // - money MUST be a decimal string, as described below
23
+ // - currency MUST be provided somewhere at the top level of your object
24
+
25
+ // Monetary amount. Decimal string with a period as a decimal separator (e.g., 3.99). Optionally, a single (-), to indicate that the amount is negative.
26
+ string value = 1 [(.wix.api.format) = DECIMAL_VALUE];
27
+ // Currency code. Must be valid ISO 4217 currency code (e.g., USD).
28
+ string currency = 2 [(.wix.api.format) = CURRENCY];
29
+ // Monetary amount. Decimal string in local format (e.g., 1 000,30). Optionally, a single (-), to indicate that the amount is negative.
30
+ google.protobuf.StringValue formatted_value = 3;
31
+
32
+ }