@deliverart/sdk-js-company 0.1.1 → 0.1.2

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/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @deliverart/sdk-js-company
2
2
 
3
+ ## 0.1.2
4
+
5
+ ### Patch Changes
6
+
7
+ - 575341f: expose adminby for editable field
8
+
3
9
  ## 0.1.1
4
10
 
5
11
  ### Patch Changes
package/dist/index.cjs CHANGED
@@ -68,7 +68,9 @@ var writableCompanySchema = companyDetailsSchema.pick({
68
68
  taxCode: true,
69
69
  billingAddress: true,
70
70
  operationalAddress: true,
71
- billingData: true
71
+ billingData: true,
72
+ adminBy: true
73
+ // Only Admin can set this
72
74
  });
73
75
  var companiesQuerySchema = import_zod.z.object({
74
76
  businessName: import_zod.z.string().optional(),
package/dist/index.d.cts CHANGED
@@ -261,7 +261,7 @@ declare const writableCompanySchema: z.ZodObject<Pick<{
261
261
  pec?: string | null | undefined;
262
262
  }>;
263
263
  adminBy: z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>;
264
- }, "businessName" | "vat" | "taxCode" | "operationalAddress" | "billingAddress" | "billingData">, "strip", z.ZodTypeAny, {
264
+ }, "businessName" | "vat" | "taxCode" | "operationalAddress" | "billingAddress" | "billingData" | "adminBy">, "strip", z.ZodTypeAny, {
265
265
  businessName: string;
266
266
  vat: string;
267
267
  taxCode: string | null;
@@ -285,6 +285,7 @@ declare const writableCompanySchema: z.ZodObject<Pick<{
285
285
  sdi?: string | null | undefined;
286
286
  pec?: string | null | undefined;
287
287
  };
288
+ adminBy: _deliverart_sdk_js_global_types.IriObject<"/users/:id">;
288
289
  }, {
289
290
  businessName: string;
290
291
  vat: string;
@@ -309,6 +310,7 @@ declare const writableCompanySchema: z.ZodObject<Pick<{
309
310
  sdi?: string | null | undefined;
310
311
  pec?: string | null | undefined;
311
312
  };
313
+ adminBy: string;
312
314
  }>;
313
315
  declare const companiesQuerySchema: z.ZodObject<{
314
316
  businessName: z.ZodOptional<z.ZodString>;
@@ -413,6 +415,7 @@ declare const createCompanyInputSchema: z.ZodObject<{
413
415
  sdi?: string | null | undefined;
414
416
  pec?: string | null | undefined;
415
417
  }>;
418
+ adminBy: z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>;
416
419
  }, "strip", z.ZodTypeAny, {
417
420
  businessName: string;
418
421
  vat: string;
@@ -437,6 +440,7 @@ declare const createCompanyInputSchema: z.ZodObject<{
437
440
  sdi?: string | null | undefined;
438
441
  pec?: string | null | undefined;
439
442
  };
443
+ adminBy: _deliverart_sdk_js_global_types.IriObject<"/users/:id">;
440
444
  }, {
441
445
  businessName: string;
442
446
  vat: string;
@@ -461,6 +465,7 @@ declare const createCompanyInputSchema: z.ZodObject<{
461
465
  sdi?: string | null | undefined;
462
466
  pec?: string | null | undefined;
463
467
  };
468
+ adminBy: string;
464
469
  }>;
465
470
  type CreateCompanyInput = z.input<typeof createCompanyInputSchema>;
466
471
  declare const createCompanyResponseSchema: z.ZodObject<{
@@ -658,6 +663,7 @@ declare class CreateCompany extends AbstractApiRequest<typeof createCompanyInput
658
663
  sdi?: string | null | undefined;
659
664
  pec?: string | null | undefined;
660
665
  }>;
666
+ adminBy: z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>;
661
667
  }, "strip", z.ZodTypeAny, {
662
668
  businessName: string;
663
669
  vat: string;
@@ -682,6 +688,7 @@ declare class CreateCompany extends AbstractApiRequest<typeof createCompanyInput
682
688
  sdi?: string | null | undefined;
683
689
  pec?: string | null | undefined;
684
690
  };
691
+ adminBy: _deliverart_sdk_js_global_types.IriObject<"/users/:id">;
685
692
  }, {
686
693
  businessName: string;
687
694
  vat: string;
@@ -706,6 +713,7 @@ declare class CreateCompany extends AbstractApiRequest<typeof createCompanyInput
706
713
  sdi?: string | null | undefined;
707
714
  pec?: string | null | undefined;
708
715
  };
716
+ adminBy: string;
709
717
  }>;
710
718
  readonly outputSchema: z.ZodObject<{
711
719
  id: z.ZodString;
@@ -1544,6 +1552,7 @@ declare const updateCompanyInputSchema: z.ZodObject<{
1544
1552
  sdi?: string | null | undefined;
1545
1553
  pec?: string | null | undefined;
1546
1554
  }>>;
1555
+ adminBy: z.ZodOptional<z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>>;
1547
1556
  }, "strip", z.ZodTypeAny, {
1548
1557
  businessName?: string | undefined;
1549
1558
  vat?: string | undefined;
@@ -1568,6 +1577,7 @@ declare const updateCompanyInputSchema: z.ZodObject<{
1568
1577
  sdi?: string | null | undefined;
1569
1578
  pec?: string | null | undefined;
1570
1579
  } | undefined;
1580
+ adminBy?: _deliverart_sdk_js_global_types.IriObject<"/users/:id"> | undefined;
1571
1581
  }, {
1572
1582
  businessName?: string | undefined;
1573
1583
  vat?: string | undefined;
@@ -1592,6 +1602,7 @@ declare const updateCompanyInputSchema: z.ZodObject<{
1592
1602
  sdi?: string | null | undefined;
1593
1603
  pec?: string | null | undefined;
1594
1604
  } | undefined;
1605
+ adminBy?: string | undefined;
1595
1606
  }>;
1596
1607
  type UpdateCompanyInput = z.input<typeof updateCompanyInputSchema>;
1597
1608
  declare const updateCompanyResponseSchema: z.ZodObject<{
@@ -1789,6 +1800,7 @@ declare class UpdateCompany extends AbstractApiRequest<typeof updateCompanyInput
1789
1800
  sdi?: string | null | undefined;
1790
1801
  pec?: string | null | undefined;
1791
1802
  }>>;
1803
+ adminBy: z.ZodOptional<z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>>;
1792
1804
  }, "strip", z.ZodTypeAny, {
1793
1805
  businessName?: string | undefined;
1794
1806
  vat?: string | undefined;
@@ -1813,6 +1825,7 @@ declare class UpdateCompany extends AbstractApiRequest<typeof updateCompanyInput
1813
1825
  sdi?: string | null | undefined;
1814
1826
  pec?: string | null | undefined;
1815
1827
  } | undefined;
1828
+ adminBy?: _deliverart_sdk_js_global_types.IriObject<"/users/:id"> | undefined;
1816
1829
  }, {
1817
1830
  businessName?: string | undefined;
1818
1831
  vat?: string | undefined;
@@ -1837,6 +1850,7 @@ declare class UpdateCompany extends AbstractApiRequest<typeof updateCompanyInput
1837
1850
  sdi?: string | null | undefined;
1838
1851
  pec?: string | null | undefined;
1839
1852
  } | undefined;
1853
+ adminBy?: string | undefined;
1840
1854
  }>;
1841
1855
  readonly outputSchema: z.ZodObject<{
1842
1856
  id: z.ZodString;
package/dist/index.d.ts CHANGED
@@ -261,7 +261,7 @@ declare const writableCompanySchema: z.ZodObject<Pick<{
261
261
  pec?: string | null | undefined;
262
262
  }>;
263
263
  adminBy: z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>;
264
- }, "businessName" | "vat" | "taxCode" | "operationalAddress" | "billingAddress" | "billingData">, "strip", z.ZodTypeAny, {
264
+ }, "businessName" | "vat" | "taxCode" | "operationalAddress" | "billingAddress" | "billingData" | "adminBy">, "strip", z.ZodTypeAny, {
265
265
  businessName: string;
266
266
  vat: string;
267
267
  taxCode: string | null;
@@ -285,6 +285,7 @@ declare const writableCompanySchema: z.ZodObject<Pick<{
285
285
  sdi?: string | null | undefined;
286
286
  pec?: string | null | undefined;
287
287
  };
288
+ adminBy: _deliverart_sdk_js_global_types.IriObject<"/users/:id">;
288
289
  }, {
289
290
  businessName: string;
290
291
  vat: string;
@@ -309,6 +310,7 @@ declare const writableCompanySchema: z.ZodObject<Pick<{
309
310
  sdi?: string | null | undefined;
310
311
  pec?: string | null | undefined;
311
312
  };
313
+ adminBy: string;
312
314
  }>;
313
315
  declare const companiesQuerySchema: z.ZodObject<{
314
316
  businessName: z.ZodOptional<z.ZodString>;
@@ -413,6 +415,7 @@ declare const createCompanyInputSchema: z.ZodObject<{
413
415
  sdi?: string | null | undefined;
414
416
  pec?: string | null | undefined;
415
417
  }>;
418
+ adminBy: z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>;
416
419
  }, "strip", z.ZodTypeAny, {
417
420
  businessName: string;
418
421
  vat: string;
@@ -437,6 +440,7 @@ declare const createCompanyInputSchema: z.ZodObject<{
437
440
  sdi?: string | null | undefined;
438
441
  pec?: string | null | undefined;
439
442
  };
443
+ adminBy: _deliverart_sdk_js_global_types.IriObject<"/users/:id">;
440
444
  }, {
441
445
  businessName: string;
442
446
  vat: string;
@@ -461,6 +465,7 @@ declare const createCompanyInputSchema: z.ZodObject<{
461
465
  sdi?: string | null | undefined;
462
466
  pec?: string | null | undefined;
463
467
  };
468
+ adminBy: string;
464
469
  }>;
465
470
  type CreateCompanyInput = z.input<typeof createCompanyInputSchema>;
466
471
  declare const createCompanyResponseSchema: z.ZodObject<{
@@ -658,6 +663,7 @@ declare class CreateCompany extends AbstractApiRequest<typeof createCompanyInput
658
663
  sdi?: string | null | undefined;
659
664
  pec?: string | null | undefined;
660
665
  }>;
666
+ adminBy: z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>;
661
667
  }, "strip", z.ZodTypeAny, {
662
668
  businessName: string;
663
669
  vat: string;
@@ -682,6 +688,7 @@ declare class CreateCompany extends AbstractApiRequest<typeof createCompanyInput
682
688
  sdi?: string | null | undefined;
683
689
  pec?: string | null | undefined;
684
690
  };
691
+ adminBy: _deliverart_sdk_js_global_types.IriObject<"/users/:id">;
685
692
  }, {
686
693
  businessName: string;
687
694
  vat: string;
@@ -706,6 +713,7 @@ declare class CreateCompany extends AbstractApiRequest<typeof createCompanyInput
706
713
  sdi?: string | null | undefined;
707
714
  pec?: string | null | undefined;
708
715
  };
716
+ adminBy: string;
709
717
  }>;
710
718
  readonly outputSchema: z.ZodObject<{
711
719
  id: z.ZodString;
@@ -1544,6 +1552,7 @@ declare const updateCompanyInputSchema: z.ZodObject<{
1544
1552
  sdi?: string | null | undefined;
1545
1553
  pec?: string | null | undefined;
1546
1554
  }>>;
1555
+ adminBy: z.ZodOptional<z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>>;
1547
1556
  }, "strip", z.ZodTypeAny, {
1548
1557
  businessName?: string | undefined;
1549
1558
  vat?: string | undefined;
@@ -1568,6 +1577,7 @@ declare const updateCompanyInputSchema: z.ZodObject<{
1568
1577
  sdi?: string | null | undefined;
1569
1578
  pec?: string | null | undefined;
1570
1579
  } | undefined;
1580
+ adminBy?: _deliverart_sdk_js_global_types.IriObject<"/users/:id"> | undefined;
1571
1581
  }, {
1572
1582
  businessName?: string | undefined;
1573
1583
  vat?: string | undefined;
@@ -1592,6 +1602,7 @@ declare const updateCompanyInputSchema: z.ZodObject<{
1592
1602
  sdi?: string | null | undefined;
1593
1603
  pec?: string | null | undefined;
1594
1604
  } | undefined;
1605
+ adminBy?: string | undefined;
1595
1606
  }>;
1596
1607
  type UpdateCompanyInput = z.input<typeof updateCompanyInputSchema>;
1597
1608
  declare const updateCompanyResponseSchema: z.ZodObject<{
@@ -1789,6 +1800,7 @@ declare class UpdateCompany extends AbstractApiRequest<typeof updateCompanyInput
1789
1800
  sdi?: string | null | undefined;
1790
1801
  pec?: string | null | undefined;
1791
1802
  }>>;
1803
+ adminBy: z.ZodOptional<z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>>;
1792
1804
  }, "strip", z.ZodTypeAny, {
1793
1805
  businessName?: string | undefined;
1794
1806
  vat?: string | undefined;
@@ -1813,6 +1825,7 @@ declare class UpdateCompany extends AbstractApiRequest<typeof updateCompanyInput
1813
1825
  sdi?: string | null | undefined;
1814
1826
  pec?: string | null | undefined;
1815
1827
  } | undefined;
1828
+ adminBy?: _deliverart_sdk_js_global_types.IriObject<"/users/:id"> | undefined;
1816
1829
  }, {
1817
1830
  businessName?: string | undefined;
1818
1831
  vat?: string | undefined;
@@ -1837,6 +1850,7 @@ declare class UpdateCompany extends AbstractApiRequest<typeof updateCompanyInput
1837
1850
  sdi?: string | null | undefined;
1838
1851
  pec?: string | null | undefined;
1839
1852
  } | undefined;
1853
+ adminBy?: string | undefined;
1840
1854
  }>;
1841
1855
  readonly outputSchema: z.ZodObject<{
1842
1856
  id: z.ZodString;
package/dist/index.js CHANGED
@@ -27,7 +27,9 @@ var writableCompanySchema = companyDetailsSchema.pick({
27
27
  taxCode: true,
28
28
  billingAddress: true,
29
29
  operationalAddress: true,
30
- billingData: true
30
+ billingData: true,
31
+ adminBy: true
32
+ // Only Admin can set this
31
33
  });
32
34
  var companiesQuerySchema = z.object({
33
35
  businessName: z.string().optional(),
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@deliverart/sdk-js-company",
3
3
  "description": "Deliverart JavaScript SDK for User Management",
4
- "version": "0.1.1",
4
+ "version": "0.1.2",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",
package/src/models.ts CHANGED
@@ -32,6 +32,7 @@ export const writableCompanySchema = companyDetailsSchema.pick({
32
32
  billingAddress: true,
33
33
  operationalAddress: true,
34
34
  billingData: true,
35
+ adminBy: true, // Only Admin can set this
35
36
  })
36
37
 
37
38
  export const companiesQuerySchema = z.object({