@authhero/kysely-adapter 10.63.1 → 10.64.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.
@@ -306,6 +306,7 @@ declare const clientInsertSchema: z.ZodObject<{
306
306
  web_origins: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
307
307
  client_aliases: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
308
308
  allowed_clients: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
309
+ connections: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
309
310
  allowed_logout_urls: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
310
311
  session_transfer: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodAny>>>;
311
312
  oidc_logout: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodAny>>>;
@@ -378,6 +379,7 @@ declare const clientInsertSchema: z.ZodObject<{
378
379
  web_origins?: string[] | undefined;
379
380
  client_aliases?: string[] | undefined;
380
381
  allowed_clients?: string[] | undefined;
382
+ connections?: string[] | undefined;
381
383
  allowed_logout_urls?: string[] | undefined;
382
384
  session_transfer?: Record<string, any> | undefined;
383
385
  oidc_logout?: Record<string, any> | undefined;
@@ -419,6 +421,7 @@ declare const clientInsertSchema: z.ZodObject<{
419
421
  web_origins?: string[] | undefined;
420
422
  client_aliases?: string[] | undefined;
421
423
  allowed_clients?: string[] | undefined;
424
+ connections?: string[] | undefined;
422
425
  allowed_logout_urls?: string[] | undefined;
423
426
  session_transfer?: Record<string, any> | undefined;
424
427
  oidc_logout?: Record<string, any> | undefined;
@@ -493,6 +496,7 @@ declare const clientSchema: z.ZodObject<{
493
496
  web_origins: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
494
497
  client_aliases: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
495
498
  allowed_clients: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
499
+ connections: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
496
500
  allowed_logout_urls: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodString, "many">>>;
497
501
  session_transfer: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodAny>>>;
498
502
  oidc_logout: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodAny>>>;
@@ -569,6 +573,7 @@ declare const clientSchema: z.ZodObject<{
569
573
  web_origins?: string[] | undefined;
570
574
  client_aliases?: string[] | undefined;
571
575
  allowed_clients?: string[] | undefined;
576
+ connections?: string[] | undefined;
572
577
  allowed_logout_urls?: string[] | undefined;
573
578
  session_transfer?: Record<string, any> | undefined;
574
579
  oidc_logout?: Record<string, any> | undefined;
@@ -612,6 +617,7 @@ declare const clientSchema: z.ZodObject<{
612
617
  web_origins?: string[] | undefined;
613
618
  client_aliases?: string[] | undefined;
614
619
  allowed_clients?: string[] | undefined;
620
+ connections?: string[] | undefined;
615
621
  allowed_logout_urls?: string[] | undefined;
616
622
  session_transfer?: Record<string, any> | undefined;
617
623
  oidc_logout?: Record<string, any> | undefined;
@@ -1504,6 +1510,41 @@ declare const LegacyClientSchema: z.ZodObject<{
1504
1510
  global: boolean;
1505
1511
  is_first_party: boolean;
1506
1512
  oidc_conformant: boolean;
1513
+ connections: {
1514
+ options: {
1515
+ provider?: string | undefined;
1516
+ client_id?: string | undefined;
1517
+ client_secret?: string | undefined;
1518
+ scope?: string | undefined;
1519
+ kid?: string | undefined;
1520
+ team_id?: string | undefined;
1521
+ realms?: string | undefined;
1522
+ authentication_method?: string | undefined;
1523
+ app_secret?: string | undefined;
1524
+ authorization_endpoint?: string | undefined;
1525
+ token_endpoint?: string | undefined;
1526
+ userinfo_endpoint?: string | undefined;
1527
+ jwks_uri?: string | undefined;
1528
+ discovery_url?: string | undefined;
1529
+ issuer?: string | undefined;
1530
+ from?: string | undefined;
1531
+ twilio_sid?: string | undefined;
1532
+ twilio_token?: string | undefined;
1533
+ icon_url?: string | undefined;
1534
+ };
1535
+ created_at: string;
1536
+ updated_at: string;
1537
+ name: string;
1538
+ strategy: string;
1539
+ id?: string | undefined;
1540
+ response_type?: AuthorizationResponseType | undefined;
1541
+ response_mode?: AuthorizationResponseMode | undefined;
1542
+ display_name?: string | undefined;
1543
+ enabled_clients?: string[] | undefined;
1544
+ is_domain_connection?: boolean | undefined;
1545
+ show_as_button?: boolean | undefined;
1546
+ metadata?: Record<string, any> | undefined;
1547
+ }[];
1507
1548
  sso: boolean;
1508
1549
  sso_disabled: boolean;
1509
1550
  cross_origin_authentication: boolean;
@@ -1611,41 +1652,6 @@ declare const LegacyClientSchema: z.ZodObject<{
1611
1652
  pushed_authorization_requests_supported?: boolean | undefined;
1612
1653
  authorization_response_iss_parameter_supported?: boolean | undefined;
1613
1654
  };
1614
- connections: {
1615
- options: {
1616
- provider?: string | undefined;
1617
- client_id?: string | undefined;
1618
- client_secret?: string | undefined;
1619
- scope?: string | undefined;
1620
- kid?: string | undefined;
1621
- team_id?: string | undefined;
1622
- realms?: string | undefined;
1623
- authentication_method?: string | undefined;
1624
- app_secret?: string | undefined;
1625
- authorization_endpoint?: string | undefined;
1626
- token_endpoint?: string | undefined;
1627
- userinfo_endpoint?: string | undefined;
1628
- jwks_uri?: string | undefined;
1629
- discovery_url?: string | undefined;
1630
- issuer?: string | undefined;
1631
- from?: string | undefined;
1632
- twilio_sid?: string | undefined;
1633
- twilio_token?: string | undefined;
1634
- icon_url?: string | undefined;
1635
- };
1636
- created_at: string;
1637
- updated_at: string;
1638
- name: string;
1639
- strategy: string;
1640
- id?: string | undefined;
1641
- response_type?: AuthorizationResponseType | undefined;
1642
- response_mode?: AuthorizationResponseMode | undefined;
1643
- display_name?: string | undefined;
1644
- enabled_clients?: string[] | undefined;
1645
- is_domain_connection?: boolean | undefined;
1646
- show_as_button?: boolean | undefined;
1647
- metadata?: Record<string, any> | undefined;
1648
- }[];
1649
1655
  description?: string | undefined;
1650
1656
  refresh_token?: Record<string, any> | undefined;
1651
1657
  client_secret?: string | undefined;
@@ -1686,6 +1692,41 @@ declare const LegacyClientSchema: z.ZodObject<{
1686
1692
  updated_at: string;
1687
1693
  name: string;
1688
1694
  client_id: string;
1695
+ connections: {
1696
+ created_at: string;
1697
+ updated_at: string;
1698
+ name: string;
1699
+ strategy: string;
1700
+ options?: {
1701
+ provider?: string | undefined;
1702
+ client_id?: string | undefined;
1703
+ client_secret?: string | undefined;
1704
+ scope?: string | undefined;
1705
+ kid?: string | undefined;
1706
+ team_id?: string | undefined;
1707
+ realms?: string | undefined;
1708
+ authentication_method?: string | undefined;
1709
+ app_secret?: string | undefined;
1710
+ authorization_endpoint?: string | undefined;
1711
+ token_endpoint?: string | undefined;
1712
+ userinfo_endpoint?: string | undefined;
1713
+ jwks_uri?: string | undefined;
1714
+ discovery_url?: string | undefined;
1715
+ issuer?: string | undefined;
1716
+ from?: string | undefined;
1717
+ twilio_sid?: string | undefined;
1718
+ twilio_token?: string | undefined;
1719
+ icon_url?: string | undefined;
1720
+ } | undefined;
1721
+ id?: string | undefined;
1722
+ response_type?: AuthorizationResponseType | undefined;
1723
+ response_mode?: AuthorizationResponseMode | undefined;
1724
+ display_name?: string | undefined;
1725
+ enabled_clients?: string[] | undefined;
1726
+ is_domain_connection?: boolean | undefined;
1727
+ show_as_button?: boolean | undefined;
1728
+ metadata?: Record<string, any> | undefined;
1729
+ }[];
1689
1730
  tenant: {
1690
1731
  created_at: string | null;
1691
1732
  updated_at: string | null;
@@ -1787,41 +1828,6 @@ declare const LegacyClientSchema: z.ZodObject<{
1787
1828
  pushed_authorization_requests_supported?: boolean | undefined;
1788
1829
  authorization_response_iss_parameter_supported?: boolean | undefined;
1789
1830
  };
1790
- connections: {
1791
- created_at: string;
1792
- updated_at: string;
1793
- name: string;
1794
- strategy: string;
1795
- options?: {
1796
- provider?: string | undefined;
1797
- client_id?: string | undefined;
1798
- client_secret?: string | undefined;
1799
- scope?: string | undefined;
1800
- kid?: string | undefined;
1801
- team_id?: string | undefined;
1802
- realms?: string | undefined;
1803
- authentication_method?: string | undefined;
1804
- app_secret?: string | undefined;
1805
- authorization_endpoint?: string | undefined;
1806
- token_endpoint?: string | undefined;
1807
- userinfo_endpoint?: string | undefined;
1808
- jwks_uri?: string | undefined;
1809
- discovery_url?: string | undefined;
1810
- issuer?: string | undefined;
1811
- from?: string | undefined;
1812
- twilio_sid?: string | undefined;
1813
- twilio_token?: string | undefined;
1814
- icon_url?: string | undefined;
1815
- } | undefined;
1816
- id?: string | undefined;
1817
- response_type?: AuthorizationResponseType | undefined;
1818
- response_mode?: AuthorizationResponseMode | undefined;
1819
- display_name?: string | undefined;
1820
- enabled_clients?: string[] | undefined;
1821
- is_domain_connection?: boolean | undefined;
1822
- show_as_button?: boolean | undefined;
1823
- metadata?: Record<string, any> | undefined;
1824
- }[];
1825
1831
  description?: string | undefined;
1826
1832
  refresh_token?: Record<string, any> | undefined;
1827
1833
  global?: boolean | undefined;
@@ -7561,6 +7567,31 @@ export interface ClientsAdapter {
7561
7567
  }>;
7562
7568
  update(tenant_id: string, client_id: string, client: Partial<Client>): Promise<boolean>;
7563
7569
  }
7570
+ export interface ClientConnectionsAdapter {
7571
+ /**
7572
+ * Get all connections enabled for a specific client
7573
+ * Returns connections in the order they were stored
7574
+ */
7575
+ listByClient(tenant_id: string, client_id: string): Promise<Connection[]>;
7576
+ /**
7577
+ * Update the connections for a client
7578
+ * The connection_ids array determines both which connections are enabled
7579
+ * and their display order on the login page
7580
+ */
7581
+ updateByClient(tenant_id: string, client_id: string, connection_ids: string[]): Promise<boolean>;
7582
+ /**
7583
+ * Get all clients that have a specific connection enabled
7584
+ */
7585
+ listByConnection(tenant_id: string, connection_id: string): Promise<string[]>;
7586
+ /**
7587
+ * Add a client to a connection (add client_id to the list of clients using this connection)
7588
+ */
7589
+ addClientToConnection(tenant_id: string, connection_id: string, client_id: string): Promise<boolean>;
7590
+ /**
7591
+ * Remove a client from a connection
7592
+ */
7593
+ removeClientFromConnection(tenant_id: string, connection_id: string, client_id: string): Promise<boolean>;
7594
+ }
7564
7595
  export interface ListClientGrantsResponse extends Totals {
7565
7596
  client_grants: ClientGrant[];
7566
7597
  }
@@ -7815,6 +7846,7 @@ export interface DataAdapters {
7815
7846
  branding: BrandingAdapter;
7816
7847
  cache?: CacheAdapter;
7817
7848
  clients: ClientsAdapter;
7849
+ clientConnections: ClientConnectionsAdapter;
7818
7850
  clientGrants: ClientGrantsAdapter;
7819
7851
  legacyClients: LegacyClientsAdapter;
7820
7852
  codes: CodesAdapter;
@@ -9323,6 +9355,7 @@ declare const sqlClientSchema: z.ZodObject<{
9323
9355
  web_origins: z.ZodString;
9324
9356
  client_aliases: z.ZodString;
9325
9357
  allowed_clients: z.ZodString;
9358
+ connections: z.ZodString;
9326
9359
  allowed_logout_urls: z.ZodString;
9327
9360
  session_transfer: z.ZodString;
9328
9361
  oidc_logout: z.ZodString;
@@ -9425,6 +9458,7 @@ declare const sqlClientSchema: z.ZodObject<{
9425
9458
  web_origins: string;
9426
9459
  client_aliases: string;
9427
9460
  allowed_clients: string;
9461
+ connections: string;
9428
9462
  session_transfer: string;
9429
9463
  grant_types: string;
9430
9464
  jwt_configuration: string;
@@ -9475,6 +9509,7 @@ declare const sqlClientSchema: z.ZodObject<{
9475
9509
  web_origins: string;
9476
9510
  client_aliases: string;
9477
9511
  allowed_clients: string;
9512
+ connections: string;
9478
9513
  session_transfer: string;
9479
9514
  grant_types: string;
9480
9515
  jwt_configuration: string;