@ganju/utils 0.0.17 → 0.0.18
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.
- package/dist/constants.d.ts +6 -0
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +14 -1
- package/dist/customCodeToken.d.ts +4 -0
- package/dist/customCodeToken.d.ts.map +1 -1
- package/dist/customCodeToken.js +9 -1
- package/dist/data.d.ts +2 -0
- package/dist/data.d.ts.map +1 -1
- package/dist/data.js +28 -1
- package/dist/dataApi.d.ts +133 -1
- package/dist/dataApi.d.ts.map +1 -1
- package/dist/dataApi.js +62 -1
- package/dist/dataDdl.d.ts.map +1 -1
- package/dist/dataDdl.js +3 -1
- package/dist/dataEngine.d.ts.map +1 -1
- package/dist/dataEngine.js +62 -0
- package/dist/dataRpc.d.ts +25 -0
- package/dist/dataRpc.d.ts.map +1 -1
- package/dist/dataTriggers.d.ts +203 -0
- package/dist/dataTriggers.d.ts.map +1 -0
- package/dist/dataTriggers.js +760 -0
- package/dist/dataTypes.d.ts +1 -0
- package/dist/dataTypes.d.ts.map +1 -1
- package/dist/index.d.ts +115 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/localizeDataError.d.ts +18 -0
- package/dist/localizeDataError.d.ts.map +1 -0
- package/dist/localizeDataError.js +359 -0
- package/dist/schema.d.ts +110 -0
- package/dist/schema.d.ts.map +1 -1
- package/dist/schema.js +84 -0
- package/dist/sdkConstants.d.ts +2 -0
- package/dist/sdkConstants.d.ts.map +1 -1
- package/dist/sdkConstants.js +3 -1
- package/package.json +1 -1
- package/src/constants.ts +17 -1
- package/src/customCodeToken.ts +14 -1
- package/src/data.ts +40 -0
- package/src/dataApi.ts +78 -2
- package/src/dataDdl.ts +3 -1
- package/src/dataEngine.ts +70 -0
- package/src/dataRpc.ts +15 -0
- package/src/dataTriggers.ts +1134 -0
- package/src/dataTypes.ts +3 -0
- package/src/index.ts +2 -0
- package/src/localizeDataError.ts +593 -0
- package/src/schema.ts +89 -0
- package/src/sdkConstants.ts +2 -0
|
@@ -0,0 +1,359 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.localizeDataError = exports.DATA_ERROR_MESSAGES_ES = void 0;
|
|
4
|
+
const constants_1 = require("./constants");
|
|
5
|
+
const ACCESS = {
|
|
6
|
+
'read only': 'solo lectura',
|
|
7
|
+
'read and add rows only': 'solo leer y agregar filas'
|
|
8
|
+
};
|
|
9
|
+
const BOUNDED = {
|
|
10
|
+
'sorting it': 'ordenarla',
|
|
11
|
+
'an aggregate over it': 'un agregado sobre ella'
|
|
12
|
+
};
|
|
13
|
+
const UNTERMINATED = {
|
|
14
|
+
comment: 'un comentario',
|
|
15
|
+
string: 'un texto entre comillas',
|
|
16
|
+
'quoted name': 'un nombre entre comillas'
|
|
17
|
+
};
|
|
18
|
+
// What a refused update appends: why the row didn't match.
|
|
19
|
+
const guardSuffix = (suffix) => {
|
|
20
|
+
const missing = /^ Row (\d+) doesn't exist in ([\s\S]+)\.$/.exec(suffix);
|
|
21
|
+
if (missing)
|
|
22
|
+
return ` La fila ${missing[1]} no existe en ${missing[2]}.`;
|
|
23
|
+
const current = /^ Current values: ([\s\S]*)\.$/.exec(suffix);
|
|
24
|
+
if (current)
|
|
25
|
+
return ` Valores actuales: ${current[1]}.`;
|
|
26
|
+
return suffix;
|
|
27
|
+
};
|
|
28
|
+
exports.DATA_ERROR_MESSAGES_ES = {
|
|
29
|
+
'Unknown column "{0}" in {1}. Columns: {2}.': 'Columna desconocida "{0}" en {1}. Columnas: {2}.',
|
|
30
|
+
'Unknown table "{0}". Tables: {1}.': 'Tabla desconocida "{0}". Tablas: {1}.',
|
|
31
|
+
'"table" is the name of a table. Tables: {0}.': '"table" es el nombre de una tabla. Tablas: {0}.',
|
|
32
|
+
'Not allowed: the assistant\'s access to "{0}" is {1}.': a => `No permitido: el acceso del asistente a "${a[0]}" es ${ACCESS[a[1]] ?? a[1]}.`,
|
|
33
|
+
"This conversation has no customer, so customer-scoped tables can't be used.": 'Esta conversación no tiene cliente, así que no se pueden usar tablas limitadas al cliente.',
|
|
34
|
+
'{0}: expected an ISO 8601 date and time.': '{0}: se esperaba una fecha y hora ISO 8601.',
|
|
35
|
+
'{0}: "{1}" is not a date and time; use ISO 8601, e.g. 2026-10-19T09:00:00-05:00.': '{0}: "{1}" no es una fecha y hora; usa ISO 8601, p. ej. 2026-10-19T09:00:00-05:00.',
|
|
36
|
+
'{0} is too long (over {1} characters).': '{0} es demasiado largo (más de {1} caracteres).',
|
|
37
|
+
'{0} is required.': '{0} es obligatorio.',
|
|
38
|
+
'{0} takes the id (a whole number) of a row in {1}.': '{0} recibe el id (un número entero) de una fila de {1}.',
|
|
39
|
+
'{0} must be a whole number.': '{0} debe ser un número entero.',
|
|
40
|
+
'{0} must be a number.': '{0} debe ser un número.',
|
|
41
|
+
'{0} must be true or false.': '{0} debe ser true o false.',
|
|
42
|
+
'{0} must be a date, YYYY-MM-DD.': '{0} debe ser una fecha, AAAA-MM-DD.',
|
|
43
|
+
'{0} must be one of: {1}.': '{0} debe ser uno de: {1}.',
|
|
44
|
+
'{0} must be an email address.': '{0} debe ser un correo electrónico.',
|
|
45
|
+
'{0} must be a URL starting with http(s)://.': '{0} debe ser una URL que empiece por http(s)://.',
|
|
46
|
+
'{0} must be a phone number.': '{0} debe ser un número de teléfono.',
|
|
47
|
+
'{0} must be text.': '{0} debe ser texto.',
|
|
48
|
+
'Column names are strings.': 'Los nombres de columna son textos.',
|
|
49
|
+
'"{0}": only one level of relation is supported (relation.column).': '"{0}": solo se admite un nivel de relación (relacion.columna).',
|
|
50
|
+
'"{0}" is not a relation, so "{1}" can\'t be used.': '"{0}" no es una relación, así que no se puede usar "{1}".',
|
|
51
|
+
'{0} is one of: {1}.': '{0} es uno de: {1}.',
|
|
52
|
+
'{0} compares with a number.': '{0} se compara con un número.',
|
|
53
|
+
'{0}: expected a value or an operator object.': '{0}: se esperaba un valor o un objeto con un operador.',
|
|
54
|
+
'"where" is an object: { column: value, column: { operator: value } }.': '"where" es un objeto: { columna: valor, columna: { operador: valor } }.',
|
|
55
|
+
'"{0}" takes a list of where objects.': '"{0}" recibe una lista de objetos where.',
|
|
56
|
+
'Each entry in "{0}" is a where object with at least one condition.': 'Cada elemento de "{0}" es un objeto where con al menos una condición.',
|
|
57
|
+
'{0}: to match several values use { "in": [...] }.': '{0}: para buscar varios valores usa { "in": [...] }.',
|
|
58
|
+
'{0}: unknown operator "{1}". Operators: {2}.': '{0}: operador desconocido "{1}". Operadores: {2}.',
|
|
59
|
+
'{0}.{1} takes a list of 1 to {2} values.': '{0}.{1} recibe una lista de 1 a {2} valores.',
|
|
60
|
+
'{0}.{1} takes text.': '{0}.{1} recibe texto.',
|
|
61
|
+
'This query uses {0} values; the limit is {1}. Use fewer "in" values or split it.': 'Esta consulta usa {0} valores; el límite es {1}. Usa menos valores en "in" o divídela.',
|
|
62
|
+
'"search" needs at least one word.': '"search" necesita al menos una palabra.',
|
|
63
|
+
'"cursor" is not one this query returned; send the same table and sort with the cursor from the previous page.': '"cursor" no es uno que haya devuelto esta consulta; envía la misma tabla y orden con el cursor de la página anterior.',
|
|
64
|
+
"A row with {0} values can't be written in one statement.": 'Una fila con {0} valores no se puede escribir en una sola instrucción.',
|
|
65
|
+
'Arguments are an object.': 'Los argumentos son un objeto.',
|
|
66
|
+
'{0} is text.': '{0} es texto.',
|
|
67
|
+
'{0} is up to {1} characters.': '{0} tiene hasta {1} caracteres.',
|
|
68
|
+
'{0} is true or false.': '{0} es true o false.',
|
|
69
|
+
'A column is an object: { "name", "type", ... }.': 'Una columna es un objeto: { "name", "type", ... }.',
|
|
70
|
+
'{0}: "type" is one of {1}.': '{0}: "type" es uno de {1}.',
|
|
71
|
+
'{0}: an enum lists 1 to {1} "values".': '{0}: un enum tiene de 1 a {1} "values".',
|
|
72
|
+
'{0}: each value is text, 1 to 100 characters.': '{0}: cada valor es un texto de 1 a 100 caracteres.',
|
|
73
|
+
'{0}: "{1}" is listed twice.': '{0}: "{1}" aparece dos veces.',
|
|
74
|
+
'{0}: only enum columns take "values".': '{0}: solo las columnas enum llevan "values".',
|
|
75
|
+
'{0}: a relation names the table it points at in "table". Tables: {1}.': '{0}: una relación indica en "table" la tabla a la que apunta. Tablas: {1}.',
|
|
76
|
+
'{0}: "onDelete" is one of {1}.': '{0}: "onDelete" es uno de {1}.',
|
|
77
|
+
"{0} is required, so deleting the row it points at can't clear it; use restrict or cascade.": '{0} es obligatoria, así que borrar la fila a la que apunta no puede vaciarla; usa restrict o cascade.',
|
|
78
|
+
'{0}: only relation columns take "table".': '{0}: solo las columnas de relación llevan "table".',
|
|
79
|
+
'{0}: only integer and decimal columns take "min".': '{0}: solo las columnas integer y decimal llevan "min".',
|
|
80
|
+
'{0}: "min" is a number.': '{0}: "min" es un número.',
|
|
81
|
+
"{0}: a {1} column can't be unique.": '{0}: una columna {1} no puede ser única.',
|
|
82
|
+
'{0}: only text columns can be searchable (text, long_text, email, url, phone, enum).': '{0}: solo las columnas de texto pueden ser buscables (text, long_text, email, url, phone, enum).',
|
|
83
|
+
'{0}: a column named "rank" can\'t be searchable; rename it (e.g. "ranking").': '{0}: una columna llamada "rank" no puede ser buscable; cámbiale el nombre (p. ej. "ranking").',
|
|
84
|
+
"{0}: a {1} column can't be filterable; mark it searchable instead.": '{0}: una columna {1} no puede ser filtrable; márcala como buscable.',
|
|
85
|
+
"{0}: a {1} column can't have a default.": '{0}: una columna {1} no puede tener valor por defecto.',
|
|
86
|
+
"{0}: a unique column can't have a default.": '{0}: una columna única no puede tener valor por defecto.',
|
|
87
|
+
'{0}: the default is below the minimum, {1}.': '{0}: el valor por defecto está por debajo del mínimo, {1}.',
|
|
88
|
+
'"access" is one of {0}.': '"access" es uno de {0}.',
|
|
89
|
+
"{0}.{1} can't be unique: these values repeat: {2}.": '{0}.{1} no puede ser única: estos valores se repiten: {2}.',
|
|
90
|
+
'{0}.{1} is required.': '{0}.{1} es obligatorio.',
|
|
91
|
+
'Another row in {0} already has this {1}.': 'Otra fila de {0} ya tiene este {1}.',
|
|
92
|
+
"{0}.{1} can't go below {2}.": '{0}.{1} no puede bajar de {2}.',
|
|
93
|
+
'Invalid value for {0}.{1} ({2}).': 'Valor no válido para {0}.{1} ({2}).',
|
|
94
|
+
"A relation in {0} points at a row that doesn't exist, or other rows still point at this one.": 'Una relación en {0} apunta a una fila que no existe, o hay otras filas que aún apuntan a esta.',
|
|
95
|
+
'The database is full: delete or archive rows to make room.': 'La base de datos está llena: elimina o archiva filas para liberar espacio.',
|
|
96
|
+
'This call uses too many values at once.': 'Esta llamada usa demasiados valores a la vez.',
|
|
97
|
+
"The database refused this change to {0}; check the values against the table's columns.": 'La base de datos rechazó este cambio en {0}; revisa los valores contra las columnas de la tabla.',
|
|
98
|
+
'{0} has about {1} rows, so {2} needs a filter on an indexed column (id, or a column marked filterable, unique or a relation), or "{3}" marked filterable so it is indexed.': a => `${a[0]} tiene unas ${a[1]} filas, así que ${BOUNDED[a[2]] ?? a[2]} necesita un filtro en una columna con índice (id, o una columna marcada como filtrable, única o una relación), o marcar "${a[3]}" como filtrable para indexarla.`,
|
|
99
|
+
'{0} has about {1} rows, so {2} needs a filter on an indexed column (id, or a column marked filterable, unique or a relation).': a => `${a[0]} tiene unas ${a[1]} filas, así que ${BOUNDED[a[2]] ?? a[2]} necesita un filtro en una columna con índice (id, o una columna marcada como filtrable, única o una relación).`,
|
|
100
|
+
'"{0}" has no searchable columns; filter with "where" instead (e.g. { "name": { "contains": "..." } }).': '"{0}" no tiene columnas buscables; filtra con "where" (p. ej. { "name": { "contains": "..." } }).',
|
|
101
|
+
'"limit" is 1 to {0}.': '"limit" va de 1 a {0}.',
|
|
102
|
+
'"sort" takes up to {0} columns.': '"sort" admite hasta {0} columnas.',
|
|
103
|
+
'"sort" is a list of column names; prefix with "-" for descending, e.g. ["-created_at"].': '"sort" es una lista de nombres de columna; antepón "-" para orden descendente, p. ej. ["-created_at"].',
|
|
104
|
+
"{0} is json and can't be sorted.": '{0} es json y no se puede ordenar.',
|
|
105
|
+
'"cursor" is not one this query returned.': '"cursor" no es uno que haya devuelto esta consulta.',
|
|
106
|
+
'"include" is a list of relation columns, e.g. ["customer"].': '"include" es una lista de columnas de relación, p. ej. ["customer"].',
|
|
107
|
+
'"{0}" is not a relation column; include takes relation columns.': '"{0}" no es una columna de relación; include recibe columnas de relación.',
|
|
108
|
+
'"aggregate" is a list of 1 to {0} { "fn": ..., "column": ... }.': '"aggregate" es una lista de 1 a {0} { "fn": ..., "column": ... }.',
|
|
109
|
+
'Each aggregate is { "fn": one of {0}, "column": ... }.': 'Cada agregado es { "fn": uno de {0}, "column": ... }.',
|
|
110
|
+
'"{0}" needs a "column".': '"{0}" necesita una "column".',
|
|
111
|
+
'{0} needs a number column; "{1}" is {2}.': '{0} necesita una columna numérica; "{1}" es {2}.',
|
|
112
|
+
'"times" multiplies two number columns.': '"times" multiplica dos columnas numéricas.',
|
|
113
|
+
'"groupBy" takes up to {0} columns.': '"groupBy" admite hasta {0} columnas.',
|
|
114
|
+
'A write needs an actor (user:, cli:, mcp:, channel:, function:, trigger: or system: followed by an id).': 'Una escritura necesita un actor (user:, cli:, mcp:, channel:, function:, trigger: o system: seguido de un id).',
|
|
115
|
+
"This organization's plan no longer includes Data, so the database is read-only. Upgrade to Pro to change it.": 'El plan de esta organización ya no incluye Data, así que la base de datos es de solo lectura. Pasa a Pro para cambiarla.',
|
|
116
|
+
'The database is full: delete or archive rows to make room. Reads, deletes and exports still work.': 'La base de datos está llena: elimina o archiva filas para liberar espacio. Leer, eliminar y exportar siguen funcionando.',
|
|
117
|
+
'{ "$ref": {0} } must point at an earlier single-row insert in this list (0-based).': '{ "$ref": {0} } debe apuntar a un insert anterior de una sola fila en esta lista (empezando en 0).',
|
|
118
|
+
'An insert takes "values", an object of column: value.': 'Un insert lleva "values", un objeto columna: valor.',
|
|
119
|
+
'{0}.{1} is set by the database; leave it out.': '{0}.{1} lo asigna la base de datos; no lo envíes.',
|
|
120
|
+
'Insert into {0} is missing required {1}.': 'Al insert en {0} le falta {1}, que es obligatorio.',
|
|
121
|
+
"{0}.{1} points at a table the assistant can't use.": '{0}.{1} apunta a una tabla que el asistente no puede usar.',
|
|
122
|
+
"{0}.{1} points at {2}, which isn't one of this caller's tables.": '{0}.{1} apunta a {2}, que no es una de las tablas de quien llama.',
|
|
123
|
+
'{0}.{1}: there is no row {2} in {3}.': '{0}.{1}: no hay ninguna fila {2} en {3}.',
|
|
124
|
+
'{0} on {1} needs "id" or "where".': '{0} en {1} necesita "id" o "where".',
|
|
125
|
+
'"id" is a whole number.': '"id" es un número entero.',
|
|
126
|
+
'{0} on {1} needs a non-empty "where".': '{0} en {1} necesita un "where" no vacío.',
|
|
127
|
+
'{0}: "where" on a write can\'t use relation paths; filter on this table\'s own columns.': '{0}: "where" en una escritura no puede usar rutas de relación; filtra por las columnas de esta tabla.',
|
|
128
|
+
'"version" is the whole number the row was read with.': '"version" es el número entero con el que se leyó la fila.',
|
|
129
|
+
'Row {0} in {1} was changed since it was read (now version {2}).': 'La fila {0} de {1} cambió desde que se leyó (ahora va en la versión {2}).',
|
|
130
|
+
'An operation is an object.': 'Una operación es un objeto.',
|
|
131
|
+
'"op" is insert, update or delete.': '"op" es insert, update o delete.',
|
|
132
|
+
'"id": { "$ref": {0} } points at a row inserted into {1}; a $ref as the id must name an insert into {2}.': '"id": { "$ref": {0} } apunta a una fila insertada en {1}; un $ref usado como id debe nombrar un insert en {2}.',
|
|
133
|
+
'An insert takes "values" (one row) or "rows" (a list), not both.': 'Un insert lleva "values" (una fila) o "rows" (una lista), no ambos.',
|
|
134
|
+
'"rows" is a list of 1 to {0} rows.': '"rows" es una lista de 1 a {0} filas.',
|
|
135
|
+
'Row {0}: {1}': (a, t) => `Fila ${a[0]}: ${t(a[1])}`,
|
|
136
|
+
'"expect" is the number of rows that must change.': '"expect" es el número de filas que deben cambiar.',
|
|
137
|
+
'This {0} would change more than {1} rows; narrow the "where".': 'Este {0} cambiaría más de {1} filas; acota el "where".',
|
|
138
|
+
'This {0} would remove more than {1} rows; narrow the "where".': 'Este {0} eliminaría más de {1} filas; acota el "where".',
|
|
139
|
+
'An update takes "set", an object of column: value.': 'Un update lleva "set", un objeto columna: valor.',
|
|
140
|
+
'{0}.{1} is set by the database.': '{0}.{1} lo asigna la base de datos.',
|
|
141
|
+
'{0}.{1}: set a value, or { "increment": n } / { "decrement": n }.': '{0}.{1}: asigna un valor, o { "increment": n } / { "decrement": n }.',
|
|
142
|
+
'{0} needs a number column and a number.': '{0} necesita una columna numérica y un número.',
|
|
143
|
+
'{0}.{1} is a whole number; {2} by a whole number.': '{0}.{1} es un número entero; usa {2} con un número entero.',
|
|
144
|
+
"Can't delete: {0} row in {1} still points at this row ({2}.{3}).": 'No se puede eliminar: {0} fila de {1} aún apunta a esta fila ({2}.{3}).',
|
|
145
|
+
"Can't delete: {0} row in {1} still points at these rows ({2}.{3}).": 'No se puede eliminar: {0} fila de {1} aún apunta a estas filas ({2}.{3}).',
|
|
146
|
+
"Can't delete: {0} row in {1} still point at this row ({2}.{3}).": 'No se puede eliminar: {0} fila de {1} aún apunta a esta fila ({2}.{3}).',
|
|
147
|
+
"Can't delete: {0} row in {1} still point at these rows ({2}.{3}).": 'No se puede eliminar: {0} fila de {1} aún apunta a estas filas ({2}.{3}).',
|
|
148
|
+
"Can't delete: {0} rows in {1} still points at this row ({2}.{3}).": 'No se puede eliminar: {0} filas de {1} aún apuntan a esta fila ({2}.{3}).',
|
|
149
|
+
"Can't delete: {0} rows in {1} still points at these rows ({2}.{3}).": 'No se puede eliminar: {0} filas de {1} aún apuntan a estas filas ({2}.{3}).',
|
|
150
|
+
"Can't delete: {0} rows in {1} still point at this row ({2}.{3}).": 'No se puede eliminar: {0} filas de {1} aún apuntan a esta fila ({2}.{3}).',
|
|
151
|
+
"Can't delete: {0} rows in {1} still point at these rows ({2}.{3}).": 'No se puede eliminar: {0} filas de {1} aún apuntan a estas filas ({2}.{3}).',
|
|
152
|
+
'This update would change more than {0} rows; narrow the "where".': 'Este update cambiaría más de {0} filas; acota el "where".',
|
|
153
|
+
'{0} on {1} changed {2} row, expected {3}; nothing was written.{4}': a => `${a[0]} en ${a[1]} cambió ${a[2]} fila, se esperaba ${a[3]}; no se escribió nada.${guardSuffix(a[4])}`,
|
|
154
|
+
'{0} on {1} changed {2} rows, expected {3}; nothing was written.{4}': a => `${a[0]} en ${a[1]} cambió ${a[2]} filas, se esperaba ${a[3]}; no se escribió nada.${guardSuffix(a[4])}`,
|
|
155
|
+
'"operations" is a list of 1 to {0} insert, update or delete operations.': '"operations" es una lista de 1 a {0} operaciones insert, update o delete.',
|
|
156
|
+
'Operation {0} ({1}): {2}': (a, t) => `Operación ${a[0]} (${a[1]}): ${t(a[2])}`,
|
|
157
|
+
'A delete preview is for the owner.': 'La vista previa de un borrado es para el dueño.',
|
|
158
|
+
'"ids" lists row ids; leave it out for every row.': '"ids" lista ids de filas; omítelo para incluir todas las filas.',
|
|
159
|
+
'A delete preview takes up to {0} ids.': 'La vista previa de un borrado admite hasta {0} ids.',
|
|
160
|
+
'There is no row {0} in {1}.': 'No hay ninguna fila {0} en {1}.',
|
|
161
|
+
'A table is an object: { "name", "columns" }.': 'Una tabla es un objeto: { "name", "columns" }.',
|
|
162
|
+
'There is already a table "{0}".': 'Ya existe una tabla "{0}".',
|
|
163
|
+
'A database holds up to {0} tables.': 'Una base de datos tiene hasta {0} tablas.',
|
|
164
|
+
'{0}: "columns" lists at least one column.': '{0}: "columns" lista al menos una columna.',
|
|
165
|
+
'A table has up to {0} columns.': 'Una tabla tiene hasta {0} columnas.',
|
|
166
|
+
'{0}.{1} is listed twice.': '{0}.{1} aparece dos veces.',
|
|
167
|
+
'"displayColumn" is one of {0}\'s columns.': '"displayColumn" es una de las columnas de {0}.',
|
|
168
|
+
'The change is an object.': 'El cambio es un objeto.',
|
|
169
|
+
'"{0}" can\'t be changed here; tables take {1}.': '"{0}" no se puede cambiar aquí; las tablas admiten {1}.',
|
|
170
|
+
"{0} can't be dropped while {1} points at it; drop or change those columns first.": 'No se puede borrar {0} mientras {1} apunte a ella; borra o cambia esas columnas primero.',
|
|
171
|
+
"{0} can't be dropped while {1} point at it; drop or change those columns first.": 'No se puede borrar {0} mientras {1} apunten a ella; borra o cambia esas columnas primero.',
|
|
172
|
+
'{0} already has a column "{1}".': '{0} ya tiene una columna "{1}".',
|
|
173
|
+
'{0}.{1} is required, so existing rows need a value: give it a default, or add it optional, fill it in and then make it required.': '{0}.{1} es obligatoria, así que las filas existentes necesitan un valor: dale un valor por defecto, o agrégala opcional, rellénala y luego hazla obligatoria.',
|
|
174
|
+
"{0}.{1} can't become {2}, required: these rows (and maybe more) don't fit: {3}. Nothing was changed.": '{0}.{1} no puede pasar a {2} obligatoria: estas filas (y quizá más) no encajan: {3}. No se cambió nada.',
|
|
175
|
+
"{0}.{1} can't become {2}, required: these rows don't fit: {3}. Nothing was changed.": '{0}.{1} no puede pasar a {2} obligatoria: estas filas no encajan: {3}. No se cambió nada.',
|
|
176
|
+
"{0}.{1} can't become {2}: these rows (and maybe more) don't fit: {3}. Nothing was changed.": '{0}.{1} no puede pasar a {2}: estas filas (y quizá más) no encajan: {3}. No se cambió nada.',
|
|
177
|
+
"{0}.{1} can't become {2}: these rows don't fit: {3}. Nothing was changed.": '{0}.{1} no puede pasar a {2}: estas filas no encajan: {3}. No se cambió nada.',
|
|
178
|
+
'The change would leave {0} row in {1} pointing at nothing; nothing was changed.': 'El cambio dejaría {0} fila de {1} apuntando a nada; no se cambió nada.',
|
|
179
|
+
'The change would leave {0} rows in {1} pointing at nothing; nothing was changed.': 'El cambio dejaría {0} filas de {1} apuntando a nada; no se cambió nada.',
|
|
180
|
+
'{0} needs at least one column; drop the table instead.': '{0} necesita al menos una columna; elimina la tabla en su lugar.',
|
|
181
|
+
'The SQL has an unterminated {0}.': a => `El SQL tiene ${UNTERMINATED[a[0]] ?? a[0]} sin cerrar.`,
|
|
182
|
+
'"sql" is the SELECT to run.': '"sql" es el SELECT que se ejecuta.',
|
|
183
|
+
'A named query is up to {0} characters.': 'Una consulta guardada tiene hasta {0} caracteres.',
|
|
184
|
+
'A named query is one statement: remove the ";" inside it.': 'Una consulta guardada es una sola instrucción: quita el ";" que tiene dentro.',
|
|
185
|
+
'A named query starts with SELECT or WITH; it only reads.': 'Una consulta guardada empieza por SELECT o WITH; solo lee.',
|
|
186
|
+
'Use named parameters (:from, :to) instead of "?", so each one can be described.': 'Usa parámetros con nombre (:from, :to) en lugar de "?", para poder describir cada uno.',
|
|
187
|
+
"{0} isn't allowed in a named query.": '{0} no está permitido en una consulta guardada.',
|
|
188
|
+
'"{0}" isn\'t one of this database\'s tables or columns; named queries read the tables you defined.': '"{0}" no es una de las tablas o columnas de esta base de datos; las consultas guardadas leen las tablas que definiste.',
|
|
189
|
+
'Parameter {0}: use lowercase letters, digits and _, starting with a letter.': 'Parámetro {0}: usa minúsculas, dígitos y _, empezando por una letra.',
|
|
190
|
+
'A named query takes up to {0} parameters.': 'Una consulta guardada admite hasta {0} parámetros.',
|
|
191
|
+
"The SQL doesn't compile: {0}.": 'El SQL no compila: {0}.',
|
|
192
|
+
"A named query reads only this database's tables, with json_each and json_tree for JSON; not other virtual tables such as dbstat.": 'Una consulta guardada lee solo las tablas de esta base de datos, con json_each y json_tree para JSON; no otras tablas virtuales como dbstat.',
|
|
193
|
+
'A named query only reads: this one would change the database.': 'Una consulta guardada solo lee: esta cambiaría la base de datos.',
|
|
194
|
+
'A named query reads only this database\'s tables, not "{0}".': 'Una consulta guardada lee solo las tablas de esta base de datos, no "{0}".',
|
|
195
|
+
"A named query reads only this database's tables.": 'Una consulta guardada lee solo las tablas de esta base de datos.',
|
|
196
|
+
'There is no named query "{0}". Named queries: {1}.': 'No hay ninguna consulta guardada "{0}". Consultas guardadas: {1}.',
|
|
197
|
+
'"params" is a list of { name, type, description }.': '"params" es una lista de { name, type, description }.',
|
|
198
|
+
'params[{0}] needs a name.': 'params[{0}] necesita un nombre.',
|
|
199
|
+
'Parameter {0}: "type" is one of {1}.': 'Parámetro {0}: "type" es uno de {1}.',
|
|
200
|
+
'Declare the type of {0} in "params".': 'Declara el tipo de {0} en "params".',
|
|
201
|
+
"The SQL doesn't use {0}.": 'El SQL no usa {0}.',
|
|
202
|
+
'A named query is an object.': 'Una consulta guardada es un objeto.',
|
|
203
|
+
'A named query needs a name: lowercase letters, digits and _, starting with a letter.': 'Una consulta guardada necesita un nombre: minúsculas, dígitos y _, empezando por una letra.',
|
|
204
|
+
'A database holds up to {0} named queries.': 'Una base de datos tiene hasta {0} consultas guardadas.',
|
|
205
|
+
'There is no named query "{0}" the assistant may run.': 'No hay ninguna consulta guardada "{0}" que el asistente pueda ejecutar.',
|
|
206
|
+
'"params" is an object, e.g. { "from": "2026-10-01" }.': '"params" es un objeto, p. ej. { "from": "2026-10-01" }.',
|
|
207
|
+
'{0} takes {1}; not {2}.': a => `${a[0]} recibe ${a[1] === 'no parameters' ? 'ningún parámetro' : a[1]}; no ${a[2]}.`,
|
|
208
|
+
'{0} reads all of {1}, which has about {2} rows; filter on an indexed column (id, or a column marked filterable, unique or a relation).': '{0} lee toda la tabla {1}, que tiene unas {2} filas; filtra por una columna con índice (id, o una columna marcada como filtrable, única o una relación).',
|
|
209
|
+
'{0} failed: {1}.': '{0} falló: {1}.',
|
|
210
|
+
'"when" is an object such as { "status": { "changedTo": "READY" } }.': '"when" es un objeto como { "status": { "changedTo": "READY" } }.',
|
|
211
|
+
'"when" nests all / any at most {0} deep.': '"when" anida all / any hasta {0} niveles.',
|
|
212
|
+
'"{0}" is a non-empty list of conditions, alone in its object.': '"{0}" es una lista no vacía de condiciones, sola en su objeto.',
|
|
213
|
+
'"when" names {0}.{1}, which doesn\'t exist.': '"when" nombra {0}.{1}, que no existe.',
|
|
214
|
+
'"when".{0} is a test: changedTo, changedFrom, changed or equals.': '"when".{0} es una prueba: changedTo, changedFrom, changed o equals.',
|
|
215
|
+
'"when".{0}.{1}: a test is changedTo, changedFrom, changed or equals.': '"when".{0}.{1}: una prueba es changedTo, changedFrom, changed o equals.',
|
|
216
|
+
'"when".{0}.changed is true.': '"when".{0}.changed es true.',
|
|
217
|
+
'"when".{0}.{1} is a text, number, true / false or null.': '"when".{0}.{1} es un texto, un número, true / false o null.',
|
|
218
|
+
'"when" holds at most {0} tests.': '"when" tiene como máximo {0} pruebas.',
|
|
219
|
+
'{0} is at most {1} characters.': '{0} tiene como máximo {1} caracteres.',
|
|
220
|
+
"{0} uses {{{1}}}, which isn't a column of {2}.": '{0} usa {{{1}}}, que no es una columna de {2}.',
|
|
221
|
+
'A trigger runs one thing: "function", "webhook", "chat", "email" or "customer".': 'Un disparador hace una sola cosa: "function", "webhook", "chat", "email" o "customer".',
|
|
222
|
+
'"function" is the name of one of this project\'s functions.': '"function" es el nombre de una de las funciones de este proyecto.',
|
|
223
|
+
'"webhook" is an https URL.': '"webhook" es una URL https.',
|
|
224
|
+
'"webhook" must use https.': '"webhook" debe usar https.',
|
|
225
|
+
'"chat" is { "channelId", "chatId", "text" }.': '"chat" es { "channelId", "chatId", "text" }.',
|
|
226
|
+
'"email" is { "to", "subject", "text" }.': '"email" es { "to", "subject", "text" }.',
|
|
227
|
+
'"email.to" is 1 to {0} email addresses.': '"email.to" son de 1 a {0} correos electrónicos.',
|
|
228
|
+
'"customer" messages the row\'s customer, so {0} must be customer-scoped.': '"customer" le escribe al cliente de la fila, así que {0} debe estar limitada al cliente.',
|
|
229
|
+
'"customer" is { "text", "template"? }.': '"customer" es { "text", "template"? }.',
|
|
230
|
+
'"customer.template" is { "name", "language", "params"? }.': '"customer.template" es { "name", "language", "params"? }.',
|
|
231
|
+
'"customer.template.params" is a list of texts.': '"customer.template.params" es una lista de textos.',
|
|
232
|
+
'A trigger is an object.': 'Un disparador es un objeto.',
|
|
233
|
+
'There is no table named {0}.': 'No hay ninguna tabla llamada {0}.',
|
|
234
|
+
'A trigger needs "table".': 'Un disparador necesita "table".',
|
|
235
|
+
'"on" is insert, update or delete.': '"on" es insert, update o delete.',
|
|
236
|
+
"A trigger's name is lowercase letters, digits, _ and -, starting with a letter.": 'El nombre de un disparador usa minúsculas, dígitos, _ y -, empezando por una letra.',
|
|
237
|
+
'"rateLimit" is 1 to {0} runs a minute.': '"rateLimit" va de 1 a {0} ejecuciones por minuto.',
|
|
238
|
+
'"enabled" is true or false.': '"enabled" es true o false.',
|
|
239
|
+
'"replace" is true or false.': '"replace" es true o false.',
|
|
240
|
+
'A trigger named {0} already exists; give this one another name.': 'Ya hay un disparador llamado {0}; ponle otro nombre a este.',
|
|
241
|
+
"{0}.{1} can't be dropped while the trigger {2} uses it; change or delete that trigger first.": '{0}.{1} no se puede eliminar mientras el disparador {2} la usa; cambia o elimina ese disparador primero.',
|
|
242
|
+
"{0}.{1} can't be dropped while the triggers {2} use it; change or delete those triggers first.": '{0}.{1} no se puede eliminar mientras los disparadores {2} la usan; cambia o elimina esos disparadores primero.',
|
|
243
|
+
'{0}.{1} is used by triggers ({2}): rename it on its own, then make the other changes.': '{0}.{1} la usan disparadores ({2}): renómbrala sola y luego haz los demás cambios.',
|
|
244
|
+
'Clearing the outbox needs "before".': 'Vaciar la bandeja de salida necesita "before".',
|
|
245
|
+
'There is no trigger named {0}.': 'No hay ningún disparador llamado {0}.',
|
|
246
|
+
'{0} is deployed from ganju.json; change it there.': '{0} se despliega desde ganju.json; cámbialo allí.',
|
|
247
|
+
'A trigger named {0} was made in the dashboard; give this one another name.': 'Ya hay un disparador llamado {0} creado en el panel; ponle otro nombre a este.',
|
|
248
|
+
'A database holds up to {0} triggers.': 'Una base de datos tiene hasta {0} disparadores.',
|
|
249
|
+
'"triggers" is a list of up to {0} triggers.': '"triggers" es una lista de hasta {0} disparadores.',
|
|
250
|
+
'Trigger {0}: {1}': (a, t) => `Disparador ${a[0]}: ${t(a[1])}`,
|
|
251
|
+
'Two triggers are named {0}; give each a "name" of its own.': 'Hay dos disparadores llamados {0}; dale a cada uno su propio "name".',
|
|
252
|
+
"This project doesn't have a database yet.": 'Este proyecto aún no tiene base de datos.',
|
|
253
|
+
'This database is deleted. It can be restored until its grace period ends.': 'Esta base de datos está eliminada. Se puede restaurar hasta que termine su periodo de gracia.',
|
|
254
|
+
'{0} is being copied to drop its column {1} ({2}% done). Tables can be changed again when it finishes.': '{0} se está copiando para eliminar su columna {1} ({2} % hecho). Las tablas se pueden cambiar de nuevo cuando termine.',
|
|
255
|
+
'{0} is being copied to change its column {1} ({2}% done). Tables can be changed again when it finishes.': '{0} se está copiando para cambiar su columna {1} ({2} % hecho). Las tablas se pueden cambiar de nuevo cuando termine.',
|
|
256
|
+
'{0} is being copied to drop its column {1} ({2}% done), and this write would change its rows. Try again when it finishes.': '{0} se está copiando para eliminar su columna {1} ({2} % hecho), y esta escritura cambiaría sus filas. Vuelve a intentarlo cuando termine.',
|
|
257
|
+
'{0} is being copied to change its column {1} ({2}% done), and this write would change its rows. Try again when it finishes.': '{0} se está copiando para cambiar su columna {1} ({2} % hecho), y esta escritura cambiaría sus filas. Vuelve a intentarlo cuando termine.',
|
|
258
|
+
'This database belongs to another project.': 'Esta base de datos pertenece a otro proyecto.',
|
|
259
|
+
'This database is deleted. Restore it instead of creating it again.': 'Esta base de datos está eliminada. Restáurala en lugar de crearla de nuevo.',
|
|
260
|
+
'"{0}" isn\'t a time zone; use an IANA name such as America/Bogota.': '"{0}" no es una zona horaria; usa un nombre IANA como America/Bogota.',
|
|
261
|
+
'Only a deleted database can be purged.': 'Solo se puede vaciar una base de datos eliminada.',
|
|
262
|
+
"This organization's plan no longer includes Data, so the database is read-only.": 'El plan de esta organización ya no incluye Data, así que la base de datos es de solo lectura.',
|
|
263
|
+
'A restore point is a time within the last 30 days.': 'Un punto de restauración es un momento de los últimos 30 días.',
|
|
264
|
+
'This database has no history yet; restore points start about a minute after its first change.': 'Esta base de datos aún no tiene historial; los puntos de restauración empiezan como un minuto después de su primer cambio.',
|
|
265
|
+
'That time is before this database had any data (its first change was {0}).': 'Ese momento es anterior a los primeros datos de esta base de datos (su primer cambio fue el {0}).',
|
|
266
|
+
'That time is before this database had any data.': 'Ese momento es anterior a los primeros datos de esta base de datos.',
|
|
267
|
+
"That restore point isn't available: {0}": 'Ese punto de restauración no está disponible: {0}',
|
|
268
|
+
'A restore needs a bookmark.': 'Una restauración necesita un marcador.',
|
|
269
|
+
'"format" is jsonl or csv.': '"format" es jsonl o csv.',
|
|
270
|
+
'An export is already running.': 'Ya hay una exportación en curso.',
|
|
271
|
+
'No such export.': 'No existe esa exportación.',
|
|
272
|
+
"This project doesn't have a database.": 'Este proyecto no tiene base de datos.',
|
|
273
|
+
'Type the database\'s name, "{0}", to delete it.': 'Escribe el nombre de la base de datos, "{0}", para eliminarla.',
|
|
274
|
+
'That bookmark is not one to restore to: use the one a checkpoint, a dropped table or column, a type change, or a restore answered with.': 'Ese marcador no sirve para restaurar: usa el que te devolvió un punto de control, una tabla o columna eliminada, un cambio de tipo o una restauración.',
|
|
275
|
+
'Type the table\'s name, "{0}", to drop it.': 'Escribe el nombre de la tabla, "{0}", para eliminarla.',
|
|
276
|
+
'There is no such run.': 'No existe esa ejecución.',
|
|
277
|
+
'Only a failed or skipped run can be tried again.': 'Solo se puede reintentar una ejecución fallida u omitida.',
|
|
278
|
+
'This run kept no event to send again.': 'Esta ejecución no guardó ningún evento para enviar de nuevo.',
|
|
279
|
+
'This export failed: {0}.': a => `Esta exportación falló: ${a[0] === 'unknown error' ? 'error desconocido' : a[0]}.`,
|
|
280
|
+
'This export is still running.': 'Esta exportación aún está en curso.',
|
|
281
|
+
'This export has no file for {0}.': 'Esta exportación no tiene archivo para {0}.',
|
|
282
|
+
'This export has no schema file.': 'Esta exportación no tiene archivo de esquema.',
|
|
283
|
+
'This export is no longer stored.': 'Esta exportación ya no está guardada.',
|
|
284
|
+
'This project has a deleted database still in its grace period. Restore it, or send "replaceDeleted": true to start a new one.': 'Este proyecto tiene una base de datos eliminada aún en su periodo de gracia. Restáurala, o envía "replaceDeleted": true para empezar una nueva.',
|
|
285
|
+
'The deleted database changed while this ran (restored, or replaced already). Reload and try again.': 'La base de datos eliminada cambió mientras esto se ejecutaba (se restauró o ya se reemplazó). Recarga e inténtalo de nuevo.',
|
|
286
|
+
'This database is not live.': 'Esta base de datos no está activa.',
|
|
287
|
+
'Only a database in its grace period can be restored.': 'Solo se puede restaurar una base de datos en su periodo de gracia.',
|
|
288
|
+
"{0} isn't a function of this project; deploy it first.": '{0} no es una función de este proyecto; publícala primero.',
|
|
289
|
+
"{0} isn't a function of this project; deploy them first.": '{0} no es una función de este proyecto; publícala primero.',
|
|
290
|
+
"{0} aren't functions of this project; deploy it first.": '{0} no son funciones de este proyecto; publícalas primero.',
|
|
291
|
+
"{0} aren't functions of this project; deploy them first.": '{0} no son funciones de este proyecto; publícalas primero.',
|
|
292
|
+
'There is no channel {0} in this project.': 'No hay ningún canal {0} en este proyecto.',
|
|
293
|
+
"A chat message goes to a Telegram group or a Slack or Discord channel; on WhatsApp, message the row's customer instead.": 'Un mensaje de chat va a un grupo de Telegram o a un canal de Slack o Discord; en WhatsApp, escríbele al cliente de la fila.',
|
|
294
|
+
'A table needs a name.': 'Una tabla necesita un nombre.',
|
|
295
|
+
'A column needs a name.': 'Una columna necesita un nombre.',
|
|
296
|
+
'"{0}" isn\'t a valid table name: use lowercase letters, digits and _, starting with a letter, up to 63 characters.': '"{0}" no es un nombre de tabla válido: usa minúsculas, dígitos y _, empezando por una letra, hasta 63 caracteres.',
|
|
297
|
+
'"{0}" isn\'t a valid column name: use lowercase letters, digits and _, starting with a letter, up to 63 characters.': '"{0}" no es un nombre de columna válido: usa minúsculas, dígitos y _, empezando por una letra, hasta 63 caracteres.',
|
|
298
|
+
'"{0}": two underscores in a row are reserved.': '"{0}": dos guiones bajos seguidos están reservados.',
|
|
299
|
+
'"{0}" is a reserved name.': '"{0}" es un nombre reservado.',
|
|
300
|
+
'"{0}" looks like one of the database\'s own index names; pick another table name.': '"{0}" parece el nombre de uno de los índices de la base de datos; elige otro nombre de tabla.',
|
|
301
|
+
'"{0}" is reserved by SQLite; pick another table name (e.g. "{1}_ref").': '"{0}" está reservado por SQLite; elige otro nombre de tabla (p. ej. "{1}_ref").',
|
|
302
|
+
'"{0}" is reserved by SQLite; pick another column name (e.g. "{1}_ref").': '"{0}" está reservado por SQLite; elige otro nombre de columna (p. ej. "{1}_ref").',
|
|
303
|
+
'"{0}" is a column every table already has.': '"{0}" es una columna que ya tienen todas las tablas.'
|
|
304
|
+
};
|
|
305
|
+
const compile = (template, render) => {
|
|
306
|
+
const parts = template.split(/\{\d+\}/);
|
|
307
|
+
return {
|
|
308
|
+
pattern: new RegExp(`^${parts.map(p => p.replace(/[.*+?^${}()|[\]\\]/g, '\\$&')).join('([\\s\\S]*?)')}$`),
|
|
309
|
+
render,
|
|
310
|
+
prefix: parts[0].length,
|
|
311
|
+
literal: parts.join('').length
|
|
312
|
+
};
|
|
313
|
+
};
|
|
314
|
+
let compiled = null;
|
|
315
|
+
// Templates that open with fixed text go first, so "Row 3: menu.name is
|
|
316
|
+
// required." is read as a row's message and not as a column called "Row 3:
|
|
317
|
+
// menu"; then the most specific.
|
|
318
|
+
const templates = () => (compiled ??= Object.entries(exports.DATA_ERROR_MESSAGES_ES)
|
|
319
|
+
.map(([template, render]) => compile(template, render))
|
|
320
|
+
.filter(c => c.literal > 0)
|
|
321
|
+
.sort((a, b) => Math.min(b.prefix, 1) - Math.min(a.prefix, 1) ||
|
|
322
|
+
b.prefix - a.prefix ||
|
|
323
|
+
b.literal - a.literal));
|
|
324
|
+
const translate = (message) => {
|
|
325
|
+
// A refused update: any message, then why the row didn't match. Split
|
|
326
|
+
// first, or a template's last value would swallow the English tail.
|
|
327
|
+
const guarded = /^([\s\S]*?\.)( Row \d+ doesn't exist in [\s\S]+\.| Current values: [\s\S]*\.)$/.exec(message);
|
|
328
|
+
if (guarded) {
|
|
329
|
+
const head = translate(guarded[1]);
|
|
330
|
+
if (head)
|
|
331
|
+
return head + guardSuffix(guarded[2]);
|
|
332
|
+
}
|
|
333
|
+
for (const { pattern, render } of templates()) {
|
|
334
|
+
const match = pattern.exec(message);
|
|
335
|
+
if (!match)
|
|
336
|
+
continue;
|
|
337
|
+
const args = match.slice(1);
|
|
338
|
+
return typeof render === 'string'
|
|
339
|
+
? render.replace(/\{(\d+)\}/g, (_, i) => args[Number(i)] ?? '')
|
|
340
|
+
: render(args, nested => translate(nested) ?? nested);
|
|
341
|
+
}
|
|
342
|
+
return null;
|
|
343
|
+
};
|
|
344
|
+
/** `message` in `language`, or as it is when there's no translation. */
|
|
345
|
+
const localizeDataError = (message, language) => {
|
|
346
|
+
if (language !== constants_1.constants.LANGUAGE_ES)
|
|
347
|
+
return message;
|
|
348
|
+
try {
|
|
349
|
+
const translated = translate(message);
|
|
350
|
+
if (!translated)
|
|
351
|
+
return message;
|
|
352
|
+
// A named query's parameter, labelled the way column values are.
|
|
353
|
+
return translated.replace(/^Parameter /, 'El parámetro ');
|
|
354
|
+
}
|
|
355
|
+
catch {
|
|
356
|
+
return message;
|
|
357
|
+
}
|
|
358
|
+
};
|
|
359
|
+
exports.localizeDataError = localizeDataError;
|
package/dist/schema.d.ts
CHANGED
|
@@ -313,6 +313,7 @@ declare const CUSTOM_CODE_TOOL: z.ZodObject<{
|
|
|
313
313
|
idempotentHint: z.ZodOptional<z.ZodBoolean>;
|
|
314
314
|
openWorldHint: z.ZodOptional<z.ZodBoolean>;
|
|
315
315
|
}, z.core.$strict>>;
|
|
316
|
+
expose: z.ZodOptional<z.ZodBoolean>;
|
|
316
317
|
data: z.ZodOptional<z.ZodObject<{
|
|
317
318
|
access: z.ZodOptional<z.ZodEnum<{
|
|
318
319
|
read: "read";
|
|
@@ -360,6 +361,7 @@ declare const CUSTOM_CODE_MANIFEST: z.ZodObject<{
|
|
|
360
361
|
idempotentHint: z.ZodOptional<z.ZodBoolean>;
|
|
361
362
|
openWorldHint: z.ZodOptional<z.ZodBoolean>;
|
|
362
363
|
}, z.core.$strict>>;
|
|
364
|
+
expose: z.ZodOptional<z.ZodBoolean>;
|
|
363
365
|
data: z.ZodOptional<z.ZodObject<{
|
|
364
366
|
access: z.ZodOptional<z.ZodEnum<{
|
|
365
367
|
read: "read";
|
|
@@ -1454,6 +1456,95 @@ export declare const Schema: {
|
|
|
1454
1456
|
organizationId: z.ZodUUID;
|
|
1455
1457
|
name: z.ZodString;
|
|
1456
1458
|
}, z.core.$strip>;
|
|
1459
|
+
DATA_TRIGGER_INPUT: z.ZodObject<{
|
|
1460
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1461
|
+
description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1462
|
+
table: z.ZodString;
|
|
1463
|
+
on: z.ZodEnum<{
|
|
1464
|
+
insert: "insert";
|
|
1465
|
+
update: "update";
|
|
1466
|
+
delete: "delete";
|
|
1467
|
+
}>;
|
|
1468
|
+
when: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
1469
|
+
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
1470
|
+
replace: z.ZodOptional<z.ZodBoolean>;
|
|
1471
|
+
rateLimit: z.ZodOptional<z.ZodNumber>;
|
|
1472
|
+
function: z.ZodOptional<z.ZodString>;
|
|
1473
|
+
webhook: z.ZodOptional<z.ZodURL>;
|
|
1474
|
+
chat: z.ZodOptional<z.ZodObject<{
|
|
1475
|
+
channelId: z.ZodString;
|
|
1476
|
+
chatId: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
|
|
1477
|
+
text: z.ZodString;
|
|
1478
|
+
}, z.core.$strict>>;
|
|
1479
|
+
email: z.ZodOptional<z.ZodObject<{
|
|
1480
|
+
to: z.ZodUnion<readonly [z.ZodEmail, z.ZodArray<z.ZodEmail>]>;
|
|
1481
|
+
subject: z.ZodOptional<z.ZodString>;
|
|
1482
|
+
text: z.ZodString;
|
|
1483
|
+
}, z.core.$strict>>;
|
|
1484
|
+
customer: z.ZodOptional<z.ZodObject<{
|
|
1485
|
+
text: z.ZodString;
|
|
1486
|
+
template: z.ZodOptional<z.ZodObject<{
|
|
1487
|
+
name: z.ZodString;
|
|
1488
|
+
language: z.ZodString;
|
|
1489
|
+
params: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1490
|
+
}, z.core.$strict>>;
|
|
1491
|
+
}, z.core.$strict>>;
|
|
1492
|
+
}, z.core.$strict>;
|
|
1493
|
+
DATA_TRIGGER_PATCH: z.ZodObject<{
|
|
1494
|
+
enabled: z.ZodBoolean;
|
|
1495
|
+
}, z.core.$strict>;
|
|
1496
|
+
DATA_TRIGGER_DEPLOY_BODY: z.ZodObject<{
|
|
1497
|
+
triggers: z.ZodArray<z.ZodObject<{
|
|
1498
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1499
|
+
description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1500
|
+
table: z.ZodString;
|
|
1501
|
+
on: z.ZodEnum<{
|
|
1502
|
+
insert: "insert";
|
|
1503
|
+
update: "update";
|
|
1504
|
+
delete: "delete";
|
|
1505
|
+
}>;
|
|
1506
|
+
when: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
1507
|
+
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
1508
|
+
replace: z.ZodOptional<z.ZodBoolean>;
|
|
1509
|
+
rateLimit: z.ZodOptional<z.ZodNumber>;
|
|
1510
|
+
function: z.ZodOptional<z.ZodString>;
|
|
1511
|
+
webhook: z.ZodOptional<z.ZodURL>;
|
|
1512
|
+
chat: z.ZodOptional<z.ZodObject<{
|
|
1513
|
+
channelId: z.ZodString;
|
|
1514
|
+
chatId: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
|
|
1515
|
+
text: z.ZodString;
|
|
1516
|
+
}, z.core.$strict>>;
|
|
1517
|
+
email: z.ZodOptional<z.ZodObject<{
|
|
1518
|
+
to: z.ZodUnion<readonly [z.ZodEmail, z.ZodArray<z.ZodEmail>]>;
|
|
1519
|
+
subject: z.ZodOptional<z.ZodString>;
|
|
1520
|
+
text: z.ZodString;
|
|
1521
|
+
}, z.core.$strict>>;
|
|
1522
|
+
customer: z.ZodOptional<z.ZodObject<{
|
|
1523
|
+
text: z.ZodString;
|
|
1524
|
+
template: z.ZodOptional<z.ZodObject<{
|
|
1525
|
+
name: z.ZodString;
|
|
1526
|
+
language: z.ZodString;
|
|
1527
|
+
params: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1528
|
+
}, z.core.$strict>>;
|
|
1529
|
+
}, z.core.$strict>>;
|
|
1530
|
+
}, z.core.$strict>>;
|
|
1531
|
+
}, z.core.$strict>;
|
|
1532
|
+
DATA_TRIGGER_RUN_LIST_QUERY: z.ZodObject<{
|
|
1533
|
+
limit: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
1534
|
+
}, z.core.$strip>;
|
|
1535
|
+
DATA_TRIGGER_PATH_PARAMS: z.ZodObject<{
|
|
1536
|
+
projectId: z.ZodUUID;
|
|
1537
|
+
userId: z.ZodUUID;
|
|
1538
|
+
organizationId: z.ZodUUID;
|
|
1539
|
+
name: z.ZodString;
|
|
1540
|
+
}, z.core.$strip>;
|
|
1541
|
+
DATA_TRIGGER_RUN_PARAMS: z.ZodObject<{
|
|
1542
|
+
projectId: z.ZodUUID;
|
|
1543
|
+
userId: z.ZodUUID;
|
|
1544
|
+
organizationId: z.ZodUUID;
|
|
1545
|
+
name: z.ZodString;
|
|
1546
|
+
runId: z.ZodString;
|
|
1547
|
+
}, z.core.$strip>;
|
|
1457
1548
|
DATA_COLUMN_PARAMS: z.ZodObject<{
|
|
1458
1549
|
projectId: z.ZodUUID;
|
|
1459
1550
|
userId: z.ZodUUID;
|
|
@@ -2332,6 +2423,7 @@ export declare const Schema: {
|
|
|
2332
2423
|
idempotentHint: z.ZodOptional<z.ZodBoolean>;
|
|
2333
2424
|
openWorldHint: z.ZodOptional<z.ZodBoolean>;
|
|
2334
2425
|
}, z.core.$strict>>;
|
|
2426
|
+
expose: z.ZodOptional<z.ZodBoolean>;
|
|
2335
2427
|
data: z.ZodOptional<z.ZodObject<{
|
|
2336
2428
|
access: z.ZodOptional<z.ZodEnum<{
|
|
2337
2429
|
read: "read";
|
|
@@ -2385,6 +2477,7 @@ export declare const Schema: {
|
|
|
2385
2477
|
idempotentHint: z.ZodOptional<z.ZodBoolean>;
|
|
2386
2478
|
openWorldHint: z.ZodOptional<z.ZodBoolean>;
|
|
2387
2479
|
}, z.core.$strict>>;
|
|
2480
|
+
expose: z.ZodOptional<z.ZodBoolean>;
|
|
2388
2481
|
data: z.ZodOptional<z.ZodObject<{
|
|
2389
2482
|
access: z.ZodOptional<z.ZodEnum<{
|
|
2390
2483
|
read: "read";
|
|
@@ -2434,6 +2527,7 @@ export declare const Schema: {
|
|
|
2434
2527
|
idempotentHint: z.ZodOptional<z.ZodBoolean>;
|
|
2435
2528
|
openWorldHint: z.ZodOptional<z.ZodBoolean>;
|
|
2436
2529
|
}, z.core.$strict>>;
|
|
2530
|
+
expose: z.ZodOptional<z.ZodBoolean>;
|
|
2437
2531
|
data: z.ZodOptional<z.ZodObject<{
|
|
2438
2532
|
access: z.ZodOptional<z.ZodEnum<{
|
|
2439
2533
|
read: "read";
|
|
@@ -2570,6 +2664,22 @@ export declare const Schema: {
|
|
|
2570
2664
|
}>;
|
|
2571
2665
|
args: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
2572
2666
|
}, z.core.$strip>;
|
|
2667
|
+
CUSTOM_CODE_BROKER_CHANNELS_SEND: z.ZodObject<{
|
|
2668
|
+
call: z.ZodString;
|
|
2669
|
+
participantId: z.ZodString;
|
|
2670
|
+
text: z.ZodOptional<z.ZodString>;
|
|
2671
|
+
template: z.ZodOptional<z.ZodObject<{
|
|
2672
|
+
name: z.ZodString;
|
|
2673
|
+
language: z.ZodString;
|
|
2674
|
+
params: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2675
|
+
}, z.core.$strict>>;
|
|
2676
|
+
}, z.core.$strip>;
|
|
2677
|
+
CUSTOM_CODE_BROKER_CHANNELS_POST: z.ZodObject<{
|
|
2678
|
+
call: z.ZodString;
|
|
2679
|
+
channelId: z.ZodString;
|
|
2680
|
+
chatId: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
|
|
2681
|
+
text: z.ZodString;
|
|
2682
|
+
}, z.core.$strip>;
|
|
2573
2683
|
CUSTOM_CODE_BROKER_RESOURCE_SEARCH: z.ZodObject<{
|
|
2574
2684
|
query: z.ZodString;
|
|
2575
2685
|
limit: z.ZodDefault<z.ZodNumber>;
|
package/dist/schema.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAmoCxB,QAAA,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgGrB,CAAC;AAyDN,QAAA,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA4CpB,CAAC;AAWH,QAAA,MAAM,kBAAkB;;;;;;;;;;iBA+CtB,CAAC;AAqCH,QAAA,MAAM,gBAAgB;;;;;kBAOX,CAAC;AAEZ,QAAA,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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