a tool for shared writing and social publishing
at feature/recommend 1768 lines 46 kB view raw
1export type Json = 2 | string 3 | number 4 | boolean 5 | null 6 | { [key: string]: Json | undefined } 7 | Json[] 8 9export type Database = { 10 graphql_public: { 11 Tables: { 12 [_ in never]: never 13 } 14 Views: { 15 [_ in never]: never 16 } 17 Functions: { 18 graphql: { 19 Args: { 20 operationName?: string 21 query?: string 22 variables?: Json 23 extensions?: Json 24 } 25 Returns: Json 26 } 27 } 28 Enums: { 29 [_ in never]: never 30 } 31 CompositeTypes: { 32 [_ in never]: never 33 } 34 } 35 public: { 36 Tables: { 37 atp_poll_records: { 38 Row: { 39 cid: string 40 created_at: string 41 record: Json 42 uri: string 43 } 44 Insert: { 45 cid: string 46 created_at?: string 47 record: Json 48 uri: string 49 } 50 Update: { 51 cid?: string 52 created_at?: string 53 record?: Json 54 uri?: string 55 } 56 Relationships: [] 57 } 58 atp_poll_votes: { 59 Row: { 60 indexed_at: string 61 poll_cid: string 62 poll_uri: string 63 record: Json 64 uri: string 65 voter_did: string 66 } 67 Insert: { 68 indexed_at?: string 69 poll_cid: string 70 poll_uri: string 71 record: Json 72 uri: string 73 voter_did: string 74 } 75 Update: { 76 indexed_at?: string 77 poll_cid?: string 78 poll_uri?: string 79 record?: Json 80 uri?: string 81 voter_did?: string 82 } 83 Relationships: [ 84 { 85 foreignKeyName: "atp_poll_votes_poll_uri_fkey" 86 columns: ["poll_uri"] 87 isOneToOne: false 88 referencedRelation: "atp_poll_records" 89 referencedColumns: ["uri"] 90 }, 91 ] 92 } 93 bsky_follows: { 94 Row: { 95 follows: string 96 identity: string 97 } 98 Insert: { 99 follows: string 100 identity?: string 101 } 102 Update: { 103 follows?: string 104 identity?: string 105 } 106 Relationships: [ 107 { 108 foreignKeyName: "bsky_follows_follows_fkey" 109 columns: ["follows"] 110 isOneToOne: false 111 referencedRelation: "identities" 112 referencedColumns: ["atp_did"] 113 }, 114 { 115 foreignKeyName: "bsky_follows_identity_fkey" 116 columns: ["identity"] 117 isOneToOne: false 118 referencedRelation: "identities" 119 referencedColumns: ["atp_did"] 120 }, 121 ] 122 } 123 bsky_posts: { 124 Row: { 125 cid: string 126 indexed_at: string 127 post_view: Json 128 uri: string 129 } 130 Insert: { 131 cid: string 132 indexed_at?: string 133 post_view: Json 134 uri: string 135 } 136 Update: { 137 cid?: string 138 indexed_at?: string 139 post_view?: Json 140 uri?: string 141 } 142 Relationships: [] 143 } 144 bsky_profiles: { 145 Row: { 146 did: string 147 handle: string | null 148 indexed_at: string 149 record: Json 150 } 151 Insert: { 152 did: string 153 handle?: string | null 154 indexed_at?: string 155 record: Json 156 } 157 Update: { 158 did?: string 159 handle?: string | null 160 indexed_at?: string 161 record?: Json 162 } 163 Relationships: [ 164 { 165 foreignKeyName: "bsky_profiles_did_fkey" 166 columns: ["did"] 167 isOneToOne: true 168 referencedRelation: "identities" 169 referencedColumns: ["atp_did"] 170 }, 171 ] 172 } 173 comments_on_documents: { 174 Row: { 175 document: string | null 176 indexed_at: string 177 profile: string | null 178 record: Json 179 uri: string 180 } 181 Insert: { 182 document?: string | null 183 indexed_at?: string 184 profile?: string | null 185 record: Json 186 uri: string 187 } 188 Update: { 189 document?: string | null 190 indexed_at?: string 191 profile?: string | null 192 record?: Json 193 uri?: string 194 } 195 Relationships: [ 196 { 197 foreignKeyName: "comments_on_documents_document_fkey" 198 columns: ["document"] 199 isOneToOne: false 200 referencedRelation: "documents" 201 referencedColumns: ["uri"] 202 }, 203 { 204 foreignKeyName: "comments_on_documents_profile_fkey" 205 columns: ["profile"] 206 isOneToOne: false 207 referencedRelation: "bsky_profiles" 208 referencedColumns: ["did"] 209 }, 210 ] 211 } 212 custom_domain_routes: { 213 Row: { 214 created_at: string 215 domain: string 216 edit_permission_token: string 217 id: string 218 route: string 219 view_permission_token: string 220 } 221 Insert: { 222 created_at?: string 223 domain: string 224 edit_permission_token: string 225 id?: string 226 route: string 227 view_permission_token: string 228 } 229 Update: { 230 created_at?: string 231 domain?: string 232 edit_permission_token?: string 233 id?: string 234 route?: string 235 view_permission_token?: string 236 } 237 Relationships: [ 238 { 239 foreignKeyName: "custom_domain_routes_domain_fkey" 240 columns: ["domain"] 241 isOneToOne: false 242 referencedRelation: "custom_domains" 243 referencedColumns: ["domain"] 244 }, 245 { 246 foreignKeyName: "custom_domain_routes_edit_permission_token_fkey" 247 columns: ["edit_permission_token"] 248 isOneToOne: false 249 referencedRelation: "permission_tokens" 250 referencedColumns: ["id"] 251 }, 252 { 253 foreignKeyName: "custom_domain_routes_view_permission_token_fkey" 254 columns: ["view_permission_token"] 255 isOneToOne: false 256 referencedRelation: "permission_tokens" 257 referencedColumns: ["id"] 258 }, 259 ] 260 } 261 custom_domains: { 262 Row: { 263 confirmed: boolean 264 created_at: string 265 domain: string 266 identity: string | null 267 identity_id: string | null 268 } 269 Insert: { 270 confirmed: boolean 271 created_at?: string 272 domain: string 273 identity?: string | null 274 identity_id?: string | null 275 } 276 Update: { 277 confirmed?: boolean 278 created_at?: string 279 domain?: string 280 identity?: string | null 281 identity_id?: string | null 282 } 283 Relationships: [ 284 { 285 foreignKeyName: "custom_domains_identity_fkey" 286 columns: ["identity"] 287 isOneToOne: false 288 referencedRelation: "identities" 289 referencedColumns: ["email"] 290 }, 291 { 292 foreignKeyName: "custom_domains_identity_id_fkey" 293 columns: ["identity_id"] 294 isOneToOne: false 295 referencedRelation: "identities" 296 referencedColumns: ["id"] 297 }, 298 ] 299 } 300 document_mentions_in_bsky: { 301 Row: { 302 document: string 303 indexed_at: string 304 link: string 305 uri: string 306 } 307 Insert: { 308 document: string 309 indexed_at?: string 310 link: string 311 uri: string 312 } 313 Update: { 314 document?: string 315 indexed_at?: string 316 link?: string 317 uri?: string 318 } 319 Relationships: [ 320 { 321 foreignKeyName: "document_mentions_in_bsky_document_fkey" 322 columns: ["document"] 323 isOneToOne: false 324 referencedRelation: "documents" 325 referencedColumns: ["uri"] 326 }, 327 { 328 foreignKeyName: "document_mentions_in_bsky_uri_fkey" 329 columns: ["uri"] 330 isOneToOne: false 331 referencedRelation: "bsky_posts" 332 referencedColumns: ["uri"] 333 }, 334 ] 335 } 336 documents: { 337 Row: { 338 data: Json 339 indexed_at: string 340 sort_date: string 341 uri: string 342 } 343 Insert: { 344 data: Json 345 indexed_at?: string 346 uri: string 347 } 348 Update: { 349 data?: Json 350 indexed_at?: string 351 uri?: string 352 } 353 Relationships: [] 354 } 355 documents_in_publications: { 356 Row: { 357 document: string 358 indexed_at: string 359 publication: string 360 } 361 Insert: { 362 document: string 363 indexed_at?: string 364 publication: string 365 } 366 Update: { 367 document?: string 368 indexed_at?: string 369 publication?: string 370 } 371 Relationships: [ 372 { 373 foreignKeyName: "documents_in_publications_document_fkey" 374 columns: ["document"] 375 isOneToOne: false 376 referencedRelation: "documents" 377 referencedColumns: ["uri"] 378 }, 379 { 380 foreignKeyName: "documents_in_publications_publication_fkey" 381 columns: ["publication"] 382 isOneToOne: false 383 referencedRelation: "publications" 384 referencedColumns: ["uri"] 385 }, 386 ] 387 } 388 email_auth_tokens: { 389 Row: { 390 confirmation_code: string 391 confirmed: boolean 392 created_at: string 393 email: string | null 394 id: string 395 identity: string | null 396 } 397 Insert: { 398 confirmation_code: string 399 confirmed?: boolean 400 created_at?: string 401 email?: string | null 402 id?: string 403 identity?: string | null 404 } 405 Update: { 406 confirmation_code?: string 407 confirmed?: boolean 408 created_at?: string 409 email?: string | null 410 id?: string 411 identity?: string | null 412 } 413 Relationships: [ 414 { 415 foreignKeyName: "email_auth_tokens_identity_fkey" 416 columns: ["identity"] 417 isOneToOne: false 418 referencedRelation: "identities" 419 referencedColumns: ["id"] 420 }, 421 ] 422 } 423 email_subscriptions_to_entity: { 424 Row: { 425 confirmation_code: string 426 confirmed: boolean 427 created_at: string 428 email: string 429 entity: string 430 id: string 431 token: string 432 } 433 Insert: { 434 confirmation_code: string 435 confirmed?: boolean 436 created_at?: string 437 email: string 438 entity: string 439 id?: string 440 token: string 441 } 442 Update: { 443 confirmation_code?: string 444 confirmed?: boolean 445 created_at?: string 446 email?: string 447 entity?: string 448 id?: string 449 token?: string 450 } 451 Relationships: [ 452 { 453 foreignKeyName: "email_subscriptions_to_entity_entity_fkey" 454 columns: ["entity"] 455 isOneToOne: false 456 referencedRelation: "entities" 457 referencedColumns: ["id"] 458 }, 459 { 460 foreignKeyName: "email_subscriptions_to_entity_token_fkey" 461 columns: ["token"] 462 isOneToOne: false 463 referencedRelation: "permission_tokens" 464 referencedColumns: ["id"] 465 }, 466 ] 467 } 468 entities: { 469 Row: { 470 created_at: string 471 id: string 472 set: string 473 } 474 Insert: { 475 created_at?: string 476 id: string 477 set: string 478 } 479 Update: { 480 created_at?: string 481 id?: string 482 set?: string 483 } 484 Relationships: [ 485 { 486 foreignKeyName: "entities_set_fkey" 487 columns: ["set"] 488 isOneToOne: false 489 referencedRelation: "entity_sets" 490 referencedColumns: ["id"] 491 }, 492 ] 493 } 494 entity_sets: { 495 Row: { 496 created_at: string 497 id: string 498 } 499 Insert: { 500 created_at?: string 501 id?: string 502 } 503 Update: { 504 created_at?: string 505 id?: string 506 } 507 Relationships: [] 508 } 509 facts: { 510 Row: { 511 attribute: string 512 created_at: string 513 data: Json 514 entity: string 515 id: string 516 updated_at: string | null 517 version: number 518 } 519 Insert: { 520 attribute: string 521 created_at?: string 522 data: Json 523 entity: string 524 id: string 525 updated_at?: string | null 526 version?: number 527 } 528 Update: { 529 attribute?: string 530 created_at?: string 531 data?: Json 532 entity?: string 533 id?: string 534 updated_at?: string | null 535 version?: number 536 } 537 Relationships: [ 538 { 539 foreignKeyName: "facts_entity_fkey" 540 columns: ["entity"] 541 isOneToOne: false 542 referencedRelation: "entities" 543 referencedColumns: ["id"] 544 }, 545 ] 546 } 547 identities: { 548 Row: { 549 atp_did: string | null 550 created_at: string 551 email: string | null 552 home_page: string 553 id: string 554 interface_state: Json | null 555 metadata: Json | null 556 } 557 Insert: { 558 atp_did?: string | null 559 created_at?: string 560 email?: string | null 561 home_page?: string 562 id?: string 563 interface_state?: Json | null 564 metadata?: Json | null 565 } 566 Update: { 567 atp_did?: string | null 568 created_at?: string 569 email?: string | null 570 home_page?: string 571 id?: string 572 interface_state?: Json | null 573 metadata?: Json | null 574 } 575 Relationships: [ 576 { 577 foreignKeyName: "identities_home_page_fkey" 578 columns: ["home_page"] 579 isOneToOne: false 580 referencedRelation: "permission_tokens" 581 referencedColumns: ["id"] 582 }, 583 ] 584 } 585 leaflets_in_publications: { 586 Row: { 587 archived: boolean | null 588 cover_image: string | null 589 description: string 590 doc: string | null 591 leaflet: string 592 publication: string 593 tags: string[] | null 594 title: string 595 } 596 Insert: { 597 archived?: boolean | null 598 cover_image?: string | null 599 description?: string 600 doc?: string | null 601 leaflet: string 602 publication: string 603 tags?: string[] | null 604 title?: string 605 } 606 Update: { 607 archived?: boolean | null 608 cover_image?: string | null 609 description?: string 610 doc?: string | null 611 leaflet?: string 612 publication?: string 613 tags?: string[] | null 614 title?: string 615 } 616 Relationships: [ 617 { 618 foreignKeyName: "leaflets_in_publications_doc_fkey" 619 columns: ["doc"] 620 isOneToOne: false 621 referencedRelation: "documents" 622 referencedColumns: ["uri"] 623 }, 624 { 625 foreignKeyName: "leaflets_in_publications_leaflet_fkey" 626 columns: ["leaflet"] 627 isOneToOne: false 628 referencedRelation: "permission_tokens" 629 referencedColumns: ["id"] 630 }, 631 { 632 foreignKeyName: "leaflets_in_publications_publication_fkey" 633 columns: ["publication"] 634 isOneToOne: false 635 referencedRelation: "publications" 636 referencedColumns: ["uri"] 637 }, 638 ] 639 } 640 leaflets_to_documents: { 641 Row: { 642 archived: boolean | null 643 cover_image: string | null 644 created_at: string 645 description: string 646 document: string 647 leaflet: string 648 tags: string[] | null 649 title: string 650 } 651 Insert: { 652 archived?: boolean | null 653 cover_image?: string | null 654 created_at?: string 655 description?: string 656 document: string 657 leaflet: string 658 tags?: string[] | null 659 title?: string 660 } 661 Update: { 662 archived?: boolean | null 663 cover_image?: string | null 664 created_at?: string 665 description?: string 666 document?: string 667 leaflet?: string 668 tags?: string[] | null 669 title?: string 670 } 671 Relationships: [ 672 { 673 foreignKeyName: "leaflets_to_documents_document_fkey" 674 columns: ["document"] 675 isOneToOne: false 676 referencedRelation: "documents" 677 referencedColumns: ["uri"] 678 }, 679 { 680 foreignKeyName: "leaflets_to_documents_leaflet_fkey" 681 columns: ["leaflet"] 682 isOneToOne: false 683 referencedRelation: "permission_tokens" 684 referencedColumns: ["id"] 685 }, 686 ] 687 } 688 notifications: { 689 Row: { 690 created_at: string 691 data: Json 692 id: string 693 read: boolean 694 recipient: string 695 } 696 Insert: { 697 created_at?: string 698 data: Json 699 id: string 700 read?: boolean 701 recipient: string 702 } 703 Update: { 704 created_at?: string 705 data?: Json 706 id?: string 707 read?: boolean 708 recipient?: string 709 } 710 Relationships: [ 711 { 712 foreignKeyName: "notifications_recipient_fkey" 713 columns: ["recipient"] 714 isOneToOne: false 715 referencedRelation: "identities" 716 referencedColumns: ["atp_did"] 717 }, 718 ] 719 } 720 oauth_session_store: { 721 Row: { 722 key: string 723 session: Json 724 } 725 Insert: { 726 key: string 727 session: Json 728 } 729 Update: { 730 key?: string 731 session?: Json 732 } 733 Relationships: [] 734 } 735 oauth_state_store: { 736 Row: { 737 key: string 738 state: Json 739 } 740 Insert: { 741 key: string 742 state: Json 743 } 744 Update: { 745 key?: string 746 state?: Json 747 } 748 Relationships: [] 749 } 750 permission_token_on_homepage: { 751 Row: { 752 archived: boolean | null 753 created_at: string 754 identity: string 755 token: string 756 } 757 Insert: { 758 archived?: boolean | null 759 created_at?: string 760 identity: string 761 token: string 762 } 763 Update: { 764 archived?: boolean | null 765 created_at?: string 766 identity?: string 767 token?: string 768 } 769 Relationships: [ 770 { 771 foreignKeyName: "permission_token_creator_identity_fkey" 772 columns: ["identity"] 773 isOneToOne: false 774 referencedRelation: "identities" 775 referencedColumns: ["id"] 776 }, 777 { 778 foreignKeyName: "permission_token_on_homepage_token_fkey" 779 columns: ["token"] 780 isOneToOne: false 781 referencedRelation: "permission_tokens" 782 referencedColumns: ["id"] 783 }, 784 ] 785 } 786 permission_token_rights: { 787 Row: { 788 change_entity_set: boolean 789 create_token: boolean 790 created_at: string 791 entity_set: string 792 read: boolean 793 token: string 794 write: boolean 795 } 796 Insert: { 797 change_entity_set?: boolean 798 create_token?: boolean 799 created_at?: string 800 entity_set: string 801 read?: boolean 802 token: string 803 write?: boolean 804 } 805 Update: { 806 change_entity_set?: boolean 807 create_token?: boolean 808 created_at?: string 809 entity_set?: string 810 read?: boolean 811 token?: string 812 write?: boolean 813 } 814 Relationships: [ 815 { 816 foreignKeyName: "permission_token_rights_entity_set_fkey" 817 columns: ["entity_set"] 818 isOneToOne: false 819 referencedRelation: "entity_sets" 820 referencedColumns: ["id"] 821 }, 822 { 823 foreignKeyName: "permission_token_rights_token_fkey" 824 columns: ["token"] 825 isOneToOne: false 826 referencedRelation: "permission_tokens" 827 referencedColumns: ["id"] 828 }, 829 ] 830 } 831 permission_tokens: { 832 Row: { 833 blocked_by_admin: boolean | null 834 id: string 835 root_entity: string 836 } 837 Insert: { 838 blocked_by_admin?: boolean | null 839 id?: string 840 root_entity: string 841 } 842 Update: { 843 blocked_by_admin?: boolean | null 844 id?: string 845 root_entity?: string 846 } 847 Relationships: [ 848 { 849 foreignKeyName: "permission_tokens_root_entity_fkey" 850 columns: ["root_entity"] 851 isOneToOne: false 852 referencedRelation: "entities" 853 referencedColumns: ["id"] 854 }, 855 ] 856 } 857 phone_number_auth_tokens: { 858 Row: { 859 confirmation_code: string 860 confirmed: boolean 861 country_code: string 862 created_at: string 863 id: string 864 phone_number: string 865 } 866 Insert: { 867 confirmation_code: string 868 confirmed?: boolean 869 country_code: string 870 created_at?: string 871 id?: string 872 phone_number: string 873 } 874 Update: { 875 confirmation_code?: string 876 confirmed?: boolean 877 country_code?: string 878 created_at?: string 879 id?: string 880 phone_number?: string 881 } 882 Relationships: [] 883 } 884 phone_rsvps_to_entity: { 885 Row: { 886 country_code: string 887 created_at: string 888 entity: string 889 id: string 890 name: string 891 phone_number: string 892 plus_ones: number 893 status: Database["public"]["Enums"]["rsvp_status"] 894 } 895 Insert: { 896 country_code: string 897 created_at?: string 898 entity: string 899 id?: string 900 name?: string 901 phone_number: string 902 plus_ones?: number 903 status: Database["public"]["Enums"]["rsvp_status"] 904 } 905 Update: { 906 country_code?: string 907 created_at?: string 908 entity?: string 909 id?: string 910 name?: string 911 phone_number?: string 912 plus_ones?: number 913 status?: Database["public"]["Enums"]["rsvp_status"] 914 } 915 Relationships: [ 916 { 917 foreignKeyName: "phone_rsvps_to_entity_entity_fkey" 918 columns: ["entity"] 919 isOneToOne: false 920 referencedRelation: "entities" 921 referencedColumns: ["id"] 922 }, 923 ] 924 } 925 poll_votes_on_entity: { 926 Row: { 927 created_at: string 928 id: string 929 option_entity: string 930 poll_entity: string 931 voter_token: string 932 } 933 Insert: { 934 created_at?: string 935 id?: string 936 option_entity: string 937 poll_entity: string 938 voter_token: string 939 } 940 Update: { 941 created_at?: string 942 id?: string 943 option_entity?: string 944 poll_entity?: string 945 voter_token?: string 946 } 947 Relationships: [ 948 { 949 foreignKeyName: "poll_votes_on_entity_option_entity_fkey" 950 columns: ["option_entity"] 951 isOneToOne: false 952 referencedRelation: "entities" 953 referencedColumns: ["id"] 954 }, 955 { 956 foreignKeyName: "poll_votes_on_entity_poll_entity_fkey" 957 columns: ["poll_entity"] 958 isOneToOne: false 959 referencedRelation: "entities" 960 referencedColumns: ["id"] 961 }, 962 ] 963 } 964 publication_domains: { 965 Row: { 966 created_at: string 967 domain: string 968 identity: string 969 publication: string 970 } 971 Insert: { 972 created_at?: string 973 domain: string 974 identity: string 975 publication: string 976 } 977 Update: { 978 created_at?: string 979 domain?: string 980 identity?: string 981 publication?: string 982 } 983 Relationships: [ 984 { 985 foreignKeyName: "publication_domains_domain_fkey" 986 columns: ["domain"] 987 isOneToOne: false 988 referencedRelation: "custom_domains" 989 referencedColumns: ["domain"] 990 }, 991 { 992 foreignKeyName: "publication_domains_identity_fkey" 993 columns: ["identity"] 994 isOneToOne: false 995 referencedRelation: "identities" 996 referencedColumns: ["atp_did"] 997 }, 998 { 999 foreignKeyName: "publication_domains_publication_fkey" 1000 columns: ["publication"] 1001 isOneToOne: false 1002 referencedRelation: "publications" 1003 referencedColumns: ["uri"] 1004 }, 1005 ] 1006 } 1007 publication_subscriptions: { 1008 Row: { 1009 created_at: string 1010 identity: string 1011 publication: string 1012 record: Json 1013 uri: string 1014 } 1015 Insert: { 1016 created_at?: string 1017 identity: string 1018 publication: string 1019 record: Json 1020 uri: string 1021 } 1022 Update: { 1023 created_at?: string 1024 identity?: string 1025 publication?: string 1026 record?: Json 1027 uri?: string 1028 } 1029 Relationships: [ 1030 { 1031 foreignKeyName: "publication_subscriptions_identity_fkey" 1032 columns: ["identity"] 1033 isOneToOne: false 1034 referencedRelation: "identities" 1035 referencedColumns: ["atp_did"] 1036 }, 1037 { 1038 foreignKeyName: "publication_subscriptions_publication_fkey" 1039 columns: ["publication"] 1040 isOneToOne: false 1041 referencedRelation: "publications" 1042 referencedColumns: ["uri"] 1043 }, 1044 ] 1045 } 1046 publications: { 1047 Row: { 1048 identity_did: string 1049 indexed_at: string 1050 name: string 1051 record: Json | null 1052 uri: string 1053 } 1054 Insert: { 1055 identity_did: string 1056 indexed_at?: string 1057 name: string 1058 record?: Json | null 1059 uri: string 1060 } 1061 Update: { 1062 identity_did?: string 1063 indexed_at?: string 1064 name?: string 1065 record?: Json | null 1066 uri?: string 1067 } 1068 Relationships: [ 1069 { 1070 foreignKeyName: "publications_identity_did_fkey" 1071 columns: ["identity_did"] 1072 isOneToOne: false 1073 referencedRelation: "identities" 1074 referencedColumns: ["atp_did"] 1075 }, 1076 ] 1077 } 1078 recommends_on_documents: { 1079 Row: { 1080 document: string 1081 indexed_at: string 1082 recommender_did: string 1083 record: Json 1084 uri: string 1085 } 1086 Insert: { 1087 document: string 1088 indexed_at?: string 1089 recommender_did: string 1090 record: Json 1091 uri: string 1092 } 1093 Update: { 1094 document?: string 1095 indexed_at?: string 1096 recommender_did?: string 1097 record?: Json 1098 uri?: string 1099 } 1100 Relationships: [ 1101 { 1102 foreignKeyName: "recommends_on_documents_document_fkey" 1103 columns: ["document"] 1104 isOneToOne: false 1105 referencedRelation: "documents" 1106 referencedColumns: ["uri"] 1107 }, 1108 { 1109 foreignKeyName: "recommends_on_documents_recommender_did_fkey" 1110 columns: ["recommender_did"] 1111 isOneToOne: false 1112 referencedRelation: "identities" 1113 referencedColumns: ["atp_did"] 1114 }, 1115 ] 1116 } 1117 replicache_clients: { 1118 Row: { 1119 client_group: string 1120 client_id: string 1121 last_mutation: number 1122 } 1123 Insert: { 1124 client_group: string 1125 client_id: string 1126 last_mutation: number 1127 } 1128 Update: { 1129 client_group?: string 1130 client_id?: string 1131 last_mutation?: number 1132 } 1133 Relationships: [] 1134 } 1135 site_standard_documents: { 1136 Row: { 1137 data: Json 1138 identity_did: string 1139 indexed_at: string 1140 uri: string 1141 } 1142 Insert: { 1143 data: Json 1144 identity_did: string 1145 indexed_at?: string 1146 uri: string 1147 } 1148 Update: { 1149 data?: Json 1150 identity_did?: string 1151 indexed_at?: string 1152 uri?: string 1153 } 1154 Relationships: [ 1155 { 1156 foreignKeyName: "site_standard_documents_identity_did_fkey" 1157 columns: ["identity_did"] 1158 isOneToOne: false 1159 referencedRelation: "identities" 1160 referencedColumns: ["atp_did"] 1161 }, 1162 ] 1163 } 1164 site_standard_documents_in_publications: { 1165 Row: { 1166 document: string 1167 indexed_at: string 1168 publication: string 1169 } 1170 Insert: { 1171 document: string 1172 indexed_at?: string 1173 publication: string 1174 } 1175 Update: { 1176 document?: string 1177 indexed_at?: string 1178 publication?: string 1179 } 1180 Relationships: [ 1181 { 1182 foreignKeyName: "site_standard_documents_in_publications_document_fkey" 1183 columns: ["document"] 1184 isOneToOne: false 1185 referencedRelation: "site_standard_documents" 1186 referencedColumns: ["uri"] 1187 }, 1188 { 1189 foreignKeyName: "site_standard_documents_in_publications_publication_fkey" 1190 columns: ["publication"] 1191 isOneToOne: false 1192 referencedRelation: "site_standard_publications" 1193 referencedColumns: ["uri"] 1194 }, 1195 ] 1196 } 1197 site_standard_publications: { 1198 Row: { 1199 data: Json 1200 identity_did: string 1201 indexed_at: string 1202 uri: string 1203 } 1204 Insert: { 1205 data: Json 1206 identity_did: string 1207 indexed_at?: string 1208 uri: string 1209 } 1210 Update: { 1211 data?: Json 1212 identity_did?: string 1213 indexed_at?: string 1214 uri?: string 1215 } 1216 Relationships: [ 1217 { 1218 foreignKeyName: "site_standard_publications_identity_did_fkey" 1219 columns: ["identity_did"] 1220 isOneToOne: false 1221 referencedRelation: "identities" 1222 referencedColumns: ["atp_did"] 1223 }, 1224 ] 1225 } 1226 site_standard_subscriptions: { 1227 Row: { 1228 created_at: string 1229 identity: string 1230 publication: string 1231 record: Json 1232 uri: string 1233 } 1234 Insert: { 1235 created_at?: string 1236 identity: string 1237 publication: string 1238 record: Json 1239 uri: string 1240 } 1241 Update: { 1242 created_at?: string 1243 identity?: string 1244 publication?: string 1245 record?: Json 1246 uri?: string 1247 } 1248 Relationships: [ 1249 { 1250 foreignKeyName: "site_standard_subscriptions_identity_fkey" 1251 columns: ["identity"] 1252 isOneToOne: false 1253 referencedRelation: "identities" 1254 referencedColumns: ["atp_did"] 1255 }, 1256 { 1257 foreignKeyName: "site_standard_subscriptions_publication_fkey" 1258 columns: ["publication"] 1259 isOneToOne: false 1260 referencedRelation: "site_standard_publications" 1261 referencedColumns: ["uri"] 1262 }, 1263 ] 1264 } 1265 subscribers_to_publications: { 1266 Row: { 1267 created_at: string 1268 identity: string 1269 publication: string 1270 } 1271 Insert: { 1272 created_at?: string 1273 identity: string 1274 publication: string 1275 } 1276 Update: { 1277 created_at?: string 1278 identity?: string 1279 publication?: string 1280 } 1281 Relationships: [ 1282 { 1283 foreignKeyName: "subscribers_to_publications_identity_fkey" 1284 columns: ["identity"] 1285 isOneToOne: false 1286 referencedRelation: "identities" 1287 referencedColumns: ["email"] 1288 }, 1289 { 1290 foreignKeyName: "subscribers_to_publications_publication_fkey" 1291 columns: ["publication"] 1292 isOneToOne: false 1293 referencedRelation: "publications" 1294 referencedColumns: ["uri"] 1295 }, 1296 ] 1297 } 1298 } 1299 Views: { 1300 [_ in never]: never 1301 } 1302 Functions: { 1303 create_identity_homepage: { 1304 Args: Record<PropertyKey, never> 1305 Returns: string 1306 } 1307 get_facts: { 1308 Args: { 1309 root: string 1310 } 1311 Returns: { 1312 attribute: string 1313 created_at: string 1314 data: Json 1315 entity: string 1316 id: string 1317 updated_at: string | null 1318 version: number 1319 }[] 1320 } 1321 get_facts_for_roots: { 1322 Args: { 1323 roots: string[] 1324 max_depth: number 1325 } 1326 Returns: { 1327 root_id: string 1328 id: string 1329 entity: string 1330 attribute: string 1331 data: Json 1332 created_at: string 1333 updated_at: string 1334 version: number 1335 }[] 1336 } 1337 get_facts_with_depth: { 1338 Args: { 1339 root: string 1340 max_depth: number 1341 } 1342 Returns: { 1343 like: unknown 1344 }[] 1345 } 1346 parse_iso_timestamp: { 1347 Args: { 1348 "": string 1349 } 1350 Returns: string 1351 } 1352 pull_data: { 1353 Args: { 1354 token_id: string 1355 client_group_id: string 1356 } 1357 Returns: Database["public"]["CompositeTypes"]["pull_result"] 1358 } 1359 search_tags: { 1360 Args: { 1361 search_query: string 1362 } 1363 Returns: { 1364 name: string 1365 document_count: number 1366 }[] 1367 } 1368 } 1369 Enums: { 1370 rsvp_status: "GOING" | "NOT_GOING" | "MAYBE" 1371 } 1372 CompositeTypes: { 1373 pull_result: { 1374 client_groups: Json | null 1375 facts: Json | null 1376 publications: Json | null 1377 } 1378 } 1379 } 1380 storage: { 1381 Tables: { 1382 buckets: { 1383 Row: { 1384 allowed_mime_types: string[] | null 1385 avif_autodetection: boolean | null 1386 created_at: string | null 1387 file_size_limit: number | null 1388 id: string 1389 name: string 1390 owner: string | null 1391 owner_id: string | null 1392 public: boolean | null 1393 updated_at: string | null 1394 } 1395 Insert: { 1396 allowed_mime_types?: string[] | null 1397 avif_autodetection?: boolean | null 1398 created_at?: string | null 1399 file_size_limit?: number | null 1400 id: string 1401 name: string 1402 owner?: string | null 1403 owner_id?: string | null 1404 public?: boolean | null 1405 updated_at?: string | null 1406 } 1407 Update: { 1408 allowed_mime_types?: string[] | null 1409 avif_autodetection?: boolean | null 1410 created_at?: string | null 1411 file_size_limit?: number | null 1412 id?: string 1413 name?: string 1414 owner?: string | null 1415 owner_id?: string | null 1416 public?: boolean | null 1417 updated_at?: string | null 1418 } 1419 Relationships: [] 1420 } 1421 migrations: { 1422 Row: { 1423 executed_at: string | null 1424 hash: string 1425 id: number 1426 name: string 1427 } 1428 Insert: { 1429 executed_at?: string | null 1430 hash: string 1431 id: number 1432 name: string 1433 } 1434 Update: { 1435 executed_at?: string | null 1436 hash?: string 1437 id?: number 1438 name?: string 1439 } 1440 Relationships: [] 1441 } 1442 objects: { 1443 Row: { 1444 bucket_id: string | null 1445 created_at: string | null 1446 id: string 1447 last_accessed_at: string | null 1448 metadata: Json | null 1449 name: string | null 1450 owner: string | null 1451 owner_id: string | null 1452 path_tokens: string[] | null 1453 updated_at: string | null 1454 version: string | null 1455 } 1456 Insert: { 1457 bucket_id?: string | null 1458 created_at?: string | null 1459 id?: string 1460 last_accessed_at?: string | null 1461 metadata?: Json | null 1462 name?: string | null 1463 owner?: string | null 1464 owner_id?: string | null 1465 path_tokens?: string[] | null 1466 updated_at?: string | null 1467 version?: string | null 1468 } 1469 Update: { 1470 bucket_id?: string | null 1471 created_at?: string | null 1472 id?: string 1473 last_accessed_at?: string | null 1474 metadata?: Json | null 1475 name?: string | null 1476 owner?: string | null 1477 owner_id?: string | null 1478 path_tokens?: string[] | null 1479 updated_at?: string | null 1480 version?: string | null 1481 } 1482 Relationships: [ 1483 { 1484 foreignKeyName: "objects_bucketId_fkey" 1485 columns: ["bucket_id"] 1486 isOneToOne: false 1487 referencedRelation: "buckets" 1488 referencedColumns: ["id"] 1489 }, 1490 ] 1491 } 1492 s3_multipart_uploads: { 1493 Row: { 1494 bucket_id: string 1495 created_at: string 1496 id: string 1497 in_progress_size: number 1498 key: string 1499 owner_id: string | null 1500 upload_signature: string 1501 version: string 1502 } 1503 Insert: { 1504 bucket_id: string 1505 created_at?: string 1506 id: string 1507 in_progress_size?: number 1508 key: string 1509 owner_id?: string | null 1510 upload_signature: string 1511 version: string 1512 } 1513 Update: { 1514 bucket_id?: string 1515 created_at?: string 1516 id?: string 1517 in_progress_size?: number 1518 key?: string 1519 owner_id?: string | null 1520 upload_signature?: string 1521 version?: string 1522 } 1523 Relationships: [ 1524 { 1525 foreignKeyName: "s3_multipart_uploads_bucket_id_fkey" 1526 columns: ["bucket_id"] 1527 isOneToOne: false 1528 referencedRelation: "buckets" 1529 referencedColumns: ["id"] 1530 }, 1531 ] 1532 } 1533 s3_multipart_uploads_parts: { 1534 Row: { 1535 bucket_id: string 1536 created_at: string 1537 etag: string 1538 id: string 1539 key: string 1540 owner_id: string | null 1541 part_number: number 1542 size: number 1543 upload_id: string 1544 version: string 1545 } 1546 Insert: { 1547 bucket_id: string 1548 created_at?: string 1549 etag: string 1550 id?: string 1551 key: string 1552 owner_id?: string | null 1553 part_number: number 1554 size?: number 1555 upload_id: string 1556 version: string 1557 } 1558 Update: { 1559 bucket_id?: string 1560 created_at?: string 1561 etag?: string 1562 id?: string 1563 key?: string 1564 owner_id?: string | null 1565 part_number?: number 1566 size?: number 1567 upload_id?: string 1568 version?: string 1569 } 1570 Relationships: [ 1571 { 1572 foreignKeyName: "s3_multipart_uploads_parts_bucket_id_fkey" 1573 columns: ["bucket_id"] 1574 isOneToOne: false 1575 referencedRelation: "buckets" 1576 referencedColumns: ["id"] 1577 }, 1578 { 1579 foreignKeyName: "s3_multipart_uploads_parts_upload_id_fkey" 1580 columns: ["upload_id"] 1581 isOneToOne: false 1582 referencedRelation: "s3_multipart_uploads" 1583 referencedColumns: ["id"] 1584 }, 1585 ] 1586 } 1587 } 1588 Views: { 1589 [_ in never]: never 1590 } 1591 Functions: { 1592 can_insert_object: { 1593 Args: { 1594 bucketid: string 1595 name: string 1596 owner: string 1597 metadata: Json 1598 } 1599 Returns: undefined 1600 } 1601 extension: { 1602 Args: { 1603 name: string 1604 } 1605 Returns: string 1606 } 1607 filename: { 1608 Args: { 1609 name: string 1610 } 1611 Returns: string 1612 } 1613 foldername: { 1614 Args: { 1615 name: string 1616 } 1617 Returns: string[] 1618 } 1619 get_size_by_bucket: { 1620 Args: Record<PropertyKey, never> 1621 Returns: { 1622 size: number 1623 bucket_id: string 1624 }[] 1625 } 1626 list_multipart_uploads_with_delimiter: { 1627 Args: { 1628 bucket_id: string 1629 prefix_param: string 1630 delimiter_param: string 1631 max_keys?: number 1632 next_key_token?: string 1633 next_upload_token?: string 1634 } 1635 Returns: { 1636 key: string 1637 id: string 1638 created_at: string 1639 }[] 1640 } 1641 list_objects_with_delimiter: { 1642 Args: { 1643 bucket_id: string 1644 prefix_param: string 1645 delimiter_param: string 1646 max_keys?: number 1647 start_after?: string 1648 next_token?: string 1649 } 1650 Returns: { 1651 name: string 1652 id: string 1653 metadata: Json 1654 updated_at: string 1655 }[] 1656 } 1657 search: { 1658 Args: { 1659 prefix: string 1660 bucketname: string 1661 limits?: number 1662 levels?: number 1663 offsets?: number 1664 search?: string 1665 sortcolumn?: string 1666 sortorder?: string 1667 } 1668 Returns: { 1669 name: string 1670 id: string 1671 updated_at: string 1672 created_at: string 1673 last_accessed_at: string 1674 metadata: Json 1675 }[] 1676 } 1677 } 1678 Enums: { 1679 [_ in never]: never 1680 } 1681 CompositeTypes: { 1682 [_ in never]: never 1683 } 1684 } 1685} 1686 1687type PublicSchema = Database[Extract<keyof Database, "public">] 1688 1689export type Tables< 1690 PublicTableNameOrOptions extends 1691 | keyof (PublicSchema["Tables"] & PublicSchema["Views"]) 1692 | { schema: keyof Database }, 1693 TableName extends PublicTableNameOrOptions extends { schema: keyof Database } 1694 ? keyof (Database[PublicTableNameOrOptions["schema"]]["Tables"] & 1695 Database[PublicTableNameOrOptions["schema"]]["Views"]) 1696 : never = never, 1697> = PublicTableNameOrOptions extends { schema: keyof Database } 1698 ? (Database[PublicTableNameOrOptions["schema"]]["Tables"] & 1699 Database[PublicTableNameOrOptions["schema"]]["Views"])[TableName] extends { 1700 Row: infer R 1701 } 1702 ? R 1703 : never 1704 : PublicTableNameOrOptions extends keyof (PublicSchema["Tables"] & 1705 PublicSchema["Views"]) 1706 ? (PublicSchema["Tables"] & 1707 PublicSchema["Views"])[PublicTableNameOrOptions] extends { 1708 Row: infer R 1709 } 1710 ? R 1711 : never 1712 : never 1713 1714export type TablesInsert< 1715 PublicTableNameOrOptions extends 1716 | keyof PublicSchema["Tables"] 1717 | { schema: keyof Database }, 1718 TableName extends PublicTableNameOrOptions extends { schema: keyof Database } 1719 ? keyof Database[PublicTableNameOrOptions["schema"]]["Tables"] 1720 : never = never, 1721> = PublicTableNameOrOptions extends { schema: keyof Database } 1722 ? Database[PublicTableNameOrOptions["schema"]]["Tables"][TableName] extends { 1723 Insert: infer I 1724 } 1725 ? I 1726 : never 1727 : PublicTableNameOrOptions extends keyof PublicSchema["Tables"] 1728 ? PublicSchema["Tables"][PublicTableNameOrOptions] extends { 1729 Insert: infer I 1730 } 1731 ? I 1732 : never 1733 : never 1734 1735export type TablesUpdate< 1736 PublicTableNameOrOptions extends 1737 | keyof PublicSchema["Tables"] 1738 | { schema: keyof Database }, 1739 TableName extends PublicTableNameOrOptions extends { schema: keyof Database } 1740 ? keyof Database[PublicTableNameOrOptions["schema"]]["Tables"] 1741 : never = never, 1742> = PublicTableNameOrOptions extends { schema: keyof Database } 1743 ? Database[PublicTableNameOrOptions["schema"]]["Tables"][TableName] extends { 1744 Update: infer U 1745 } 1746 ? U 1747 : never 1748 : PublicTableNameOrOptions extends keyof PublicSchema["Tables"] 1749 ? PublicSchema["Tables"][PublicTableNameOrOptions] extends { 1750 Update: infer U 1751 } 1752 ? U 1753 : never 1754 : never 1755 1756export type Enums< 1757 PublicEnumNameOrOptions extends 1758 | keyof PublicSchema["Enums"] 1759 | { schema: keyof Database }, 1760 EnumName extends PublicEnumNameOrOptions extends { schema: keyof Database } 1761 ? keyof Database[PublicEnumNameOrOptions["schema"]]["Enums"] 1762 : never = never, 1763> = PublicEnumNameOrOptions extends { schema: keyof Database } 1764 ? Database[PublicEnumNameOrOptions["schema"]]["Enums"][EnumName] 1765 : PublicEnumNameOrOptions extends keyof PublicSchema["Enums"] 1766 ? PublicSchema["Enums"][PublicEnumNameOrOptions] 1767 : never 1768