Barazo AppView backend barazo.forum
at main 3761 lines 101 kB view raw
1{ 2 "id": "021aacdb-67eb-4c57-93aa-7f7166a8e364", 3 "prevId": "00000000-0000-0000-0000-000000000000", 4 "version": "7", 5 "dialect": "postgresql", 6 "tables": { 7 "public.users": { 8 "name": "users", 9 "schema": "", 10 "columns": { 11 "did": { 12 "name": "did", 13 "type": "text", 14 "primaryKey": true, 15 "notNull": true 16 }, 17 "handle": { 18 "name": "handle", 19 "type": "text", 20 "primaryKey": false, 21 "notNull": true 22 }, 23 "display_name": { 24 "name": "display_name", 25 "type": "text", 26 "primaryKey": false, 27 "notNull": false 28 }, 29 "avatar_url": { 30 "name": "avatar_url", 31 "type": "text", 32 "primaryKey": false, 33 "notNull": false 34 }, 35 "banner_url": { 36 "name": "banner_url", 37 "type": "text", 38 "primaryKey": false, 39 "notNull": false 40 }, 41 "bio": { 42 "name": "bio", 43 "type": "text", 44 "primaryKey": false, 45 "notNull": false 46 }, 47 "role": { 48 "name": "role", 49 "type": "text", 50 "primaryKey": false, 51 "notNull": true, 52 "default": "'user'" 53 }, 54 "is_banned": { 55 "name": "is_banned", 56 "type": "boolean", 57 "primaryKey": false, 58 "notNull": true, 59 "default": false 60 }, 61 "reputation_score": { 62 "name": "reputation_score", 63 "type": "integer", 64 "primaryKey": false, 65 "notNull": true, 66 "default": 0 67 }, 68 "first_seen_at": { 69 "name": "first_seen_at", 70 "type": "timestamp with time zone", 71 "primaryKey": false, 72 "notNull": true, 73 "default": "now()" 74 }, 75 "last_active_at": { 76 "name": "last_active_at", 77 "type": "timestamp with time zone", 78 "primaryKey": false, 79 "notNull": true, 80 "default": "now()" 81 }, 82 "declared_age": { 83 "name": "declared_age", 84 "type": "integer", 85 "primaryKey": false, 86 "notNull": false 87 }, 88 "maturity_pref": { 89 "name": "maturity_pref", 90 "type": "text", 91 "primaryKey": false, 92 "notNull": true, 93 "default": "'safe'" 94 }, 95 "account_created_at": { 96 "name": "account_created_at", 97 "type": "timestamp with time zone", 98 "primaryKey": false, 99 "notNull": false 100 }, 101 "followers_count": { 102 "name": "followers_count", 103 "type": "integer", 104 "primaryKey": false, 105 "notNull": true, 106 "default": 0 107 }, 108 "follows_count": { 109 "name": "follows_count", 110 "type": "integer", 111 "primaryKey": false, 112 "notNull": true, 113 "default": 0 114 }, 115 "atproto_posts_count": { 116 "name": "atproto_posts_count", 117 "type": "integer", 118 "primaryKey": false, 119 "notNull": true, 120 "default": 0 121 }, 122 "has_bluesky_profile": { 123 "name": "has_bluesky_profile", 124 "type": "boolean", 125 "primaryKey": false, 126 "notNull": true, 127 "default": false 128 }, 129 "atproto_labels": { 130 "name": "atproto_labels", 131 "type": "jsonb", 132 "primaryKey": false, 133 "notNull": true, 134 "default": "'[]'::jsonb" 135 } 136 }, 137 "indexes": { 138 "users_role_elevated_idx": { 139 "name": "users_role_elevated_idx", 140 "columns": [ 141 { 142 "expression": "role", 143 "isExpression": false, 144 "asc": true, 145 "nulls": "last" 146 } 147 ], 148 "isUnique": false, 149 "where": "role IN ('moderator', 'admin')", 150 "concurrently": false, 151 "method": "btree", 152 "with": {} 153 }, 154 "users_handle_idx": { 155 "name": "users_handle_idx", 156 "columns": [ 157 { 158 "expression": "handle", 159 "isExpression": false, 160 "asc": true, 161 "nulls": "last" 162 } 163 ], 164 "isUnique": false, 165 "concurrently": false, 166 "method": "btree", 167 "with": {} 168 }, 169 "users_account_created_at_idx": { 170 "name": "users_account_created_at_idx", 171 "columns": [ 172 { 173 "expression": "account_created_at", 174 "isExpression": false, 175 "asc": true, 176 "nulls": "last" 177 } 178 ], 179 "isUnique": false, 180 "concurrently": false, 181 "method": "btree", 182 "with": {} 183 } 184 }, 185 "foreignKeys": {}, 186 "compositePrimaryKeys": {}, 187 "uniqueConstraints": {}, 188 "policies": {}, 189 "checkConstraints": {}, 190 "isRLSEnabled": false 191 }, 192 "public.firehose_cursor": { 193 "name": "firehose_cursor", 194 "schema": "", 195 "columns": { 196 "id": { 197 "name": "id", 198 "type": "text", 199 "primaryKey": true, 200 "notNull": true, 201 "default": "'default'" 202 }, 203 "cursor": { 204 "name": "cursor", 205 "type": "bigint", 206 "primaryKey": false, 207 "notNull": false 208 }, 209 "updated_at": { 210 "name": "updated_at", 211 "type": "timestamp with time zone", 212 "primaryKey": false, 213 "notNull": true, 214 "default": "now()" 215 } 216 }, 217 "indexes": {}, 218 "foreignKeys": {}, 219 "compositePrimaryKeys": {}, 220 "uniqueConstraints": {}, 221 "policies": {}, 222 "checkConstraints": {}, 223 "isRLSEnabled": false 224 }, 225 "public.topics": { 226 "name": "topics", 227 "schema": "", 228 "columns": { 229 "uri": { 230 "name": "uri", 231 "type": "text", 232 "primaryKey": true, 233 "notNull": true 234 }, 235 "rkey": { 236 "name": "rkey", 237 "type": "text", 238 "primaryKey": false, 239 "notNull": true 240 }, 241 "author_did": { 242 "name": "author_did", 243 "type": "text", 244 "primaryKey": false, 245 "notNull": true 246 }, 247 "title": { 248 "name": "title", 249 "type": "text", 250 "primaryKey": false, 251 "notNull": true 252 }, 253 "content": { 254 "name": "content", 255 "type": "text", 256 "primaryKey": false, 257 "notNull": true 258 }, 259 "content_format": { 260 "name": "content_format", 261 "type": "text", 262 "primaryKey": false, 263 "notNull": false 264 }, 265 "category": { 266 "name": "category", 267 "type": "text", 268 "primaryKey": false, 269 "notNull": true 270 }, 271 "tags": { 272 "name": "tags", 273 "type": "jsonb", 274 "primaryKey": false, 275 "notNull": false 276 }, 277 "community_did": { 278 "name": "community_did", 279 "type": "text", 280 "primaryKey": false, 281 "notNull": true 282 }, 283 "cid": { 284 "name": "cid", 285 "type": "text", 286 "primaryKey": false, 287 "notNull": true 288 }, 289 "labels": { 290 "name": "labels", 291 "type": "jsonb", 292 "primaryKey": false, 293 "notNull": false 294 }, 295 "reply_count": { 296 "name": "reply_count", 297 "type": "integer", 298 "primaryKey": false, 299 "notNull": true, 300 "default": 0 301 }, 302 "reaction_count": { 303 "name": "reaction_count", 304 "type": "integer", 305 "primaryKey": false, 306 "notNull": true, 307 "default": 0 308 }, 309 "vote_count": { 310 "name": "vote_count", 311 "type": "integer", 312 "primaryKey": false, 313 "notNull": true, 314 "default": 0 315 }, 316 "last_activity_at": { 317 "name": "last_activity_at", 318 "type": "timestamp with time zone", 319 "primaryKey": false, 320 "notNull": true, 321 "default": "now()" 322 }, 323 "created_at": { 324 "name": "created_at", 325 "type": "timestamp with time zone", 326 "primaryKey": false, 327 "notNull": true 328 }, 329 "indexed_at": { 330 "name": "indexed_at", 331 "type": "timestamp with time zone", 332 "primaryKey": false, 333 "notNull": true, 334 "default": "now()" 335 }, 336 "is_locked": { 337 "name": "is_locked", 338 "type": "boolean", 339 "primaryKey": false, 340 "notNull": true, 341 "default": false 342 }, 343 "is_pinned": { 344 "name": "is_pinned", 345 "type": "boolean", 346 "primaryKey": false, 347 "notNull": true, 348 "default": false 349 }, 350 "is_mod_deleted": { 351 "name": "is_mod_deleted", 352 "type": "boolean", 353 "primaryKey": false, 354 "notNull": true, 355 "default": false 356 }, 357 "is_author_deleted": { 358 "name": "is_author_deleted", 359 "type": "boolean", 360 "primaryKey": false, 361 "notNull": true, 362 "default": false 363 }, 364 "moderation_status": { 365 "name": "moderation_status", 366 "type": "text", 367 "primaryKey": false, 368 "notNull": true, 369 "default": "'approved'" 370 }, 371 "trust_status": { 372 "name": "trust_status", 373 "type": "text", 374 "primaryKey": false, 375 "notNull": true, 376 "default": "'trusted'" 377 } 378 }, 379 "indexes": { 380 "topics_author_did_idx": { 381 "name": "topics_author_did_idx", 382 "columns": [ 383 { 384 "expression": "author_did", 385 "isExpression": false, 386 "asc": true, 387 "nulls": "last" 388 } 389 ], 390 "isUnique": false, 391 "concurrently": false, 392 "method": "btree", 393 "with": {} 394 }, 395 "topics_category_idx": { 396 "name": "topics_category_idx", 397 "columns": [ 398 { 399 "expression": "category", 400 "isExpression": false, 401 "asc": true, 402 "nulls": "last" 403 } 404 ], 405 "isUnique": false, 406 "concurrently": false, 407 "method": "btree", 408 "with": {} 409 }, 410 "topics_created_at_idx": { 411 "name": "topics_created_at_idx", 412 "columns": [ 413 { 414 "expression": "created_at", 415 "isExpression": false, 416 "asc": true, 417 "nulls": "last" 418 } 419 ], 420 "isUnique": false, 421 "concurrently": false, 422 "method": "btree", 423 "with": {} 424 }, 425 "topics_last_activity_at_idx": { 426 "name": "topics_last_activity_at_idx", 427 "columns": [ 428 { 429 "expression": "last_activity_at", 430 "isExpression": false, 431 "asc": true, 432 "nulls": "last" 433 } 434 ], 435 "isUnique": false, 436 "concurrently": false, 437 "method": "btree", 438 "with": {} 439 }, 440 "topics_community_did_idx": { 441 "name": "topics_community_did_idx", 442 "columns": [ 443 { 444 "expression": "community_did", 445 "isExpression": false, 446 "asc": true, 447 "nulls": "last" 448 } 449 ], 450 "isUnique": false, 451 "concurrently": false, 452 "method": "btree", 453 "with": {} 454 }, 455 "topics_moderation_status_idx": { 456 "name": "topics_moderation_status_idx", 457 "columns": [ 458 { 459 "expression": "moderation_status", 460 "isExpression": false, 461 "asc": true, 462 "nulls": "last" 463 } 464 ], 465 "isUnique": false, 466 "concurrently": false, 467 "method": "btree", 468 "with": {} 469 }, 470 "topics_trust_status_idx": { 471 "name": "topics_trust_status_idx", 472 "columns": [ 473 { 474 "expression": "trust_status", 475 "isExpression": false, 476 "asc": true, 477 "nulls": "last" 478 } 479 ], 480 "isUnique": false, 481 "concurrently": false, 482 "method": "btree", 483 "with": {} 484 }, 485 "topics_community_category_activity_idx": { 486 "name": "topics_community_category_activity_idx", 487 "columns": [ 488 { 489 "expression": "community_did", 490 "isExpression": false, 491 "asc": true, 492 "nulls": "last" 493 }, 494 { 495 "expression": "category", 496 "isExpression": false, 497 "asc": true, 498 "nulls": "last" 499 }, 500 { 501 "expression": "last_activity_at", 502 "isExpression": false, 503 "asc": true, 504 "nulls": "last" 505 } 506 ], 507 "isUnique": false, 508 "concurrently": false, 509 "method": "btree", 510 "with": {} 511 } 512 }, 513 "foreignKeys": {}, 514 "compositePrimaryKeys": {}, 515 "uniqueConstraints": {}, 516 "policies": { 517 "tenant_isolation": { 518 "name": "tenant_isolation", 519 "as": "PERMISSIVE", 520 "for": "ALL", 521 "to": ["barazo_app"], 522 "using": "community_did = current_setting('app.current_community_did', true)", 523 "withCheck": "community_did = current_setting('app.current_community_did', true)" 524 } 525 }, 526 "checkConstraints": {}, 527 "isRLSEnabled": true 528 }, 529 "public.replies": { 530 "name": "replies", 531 "schema": "", 532 "columns": { 533 "uri": { 534 "name": "uri", 535 "type": "text", 536 "primaryKey": true, 537 "notNull": true 538 }, 539 "rkey": { 540 "name": "rkey", 541 "type": "text", 542 "primaryKey": false, 543 "notNull": true 544 }, 545 "author_did": { 546 "name": "author_did", 547 "type": "text", 548 "primaryKey": false, 549 "notNull": true 550 }, 551 "content": { 552 "name": "content", 553 "type": "text", 554 "primaryKey": false, 555 "notNull": true 556 }, 557 "content_format": { 558 "name": "content_format", 559 "type": "text", 560 "primaryKey": false, 561 "notNull": false 562 }, 563 "root_uri": { 564 "name": "root_uri", 565 "type": "text", 566 "primaryKey": false, 567 "notNull": true 568 }, 569 "root_cid": { 570 "name": "root_cid", 571 "type": "text", 572 "primaryKey": false, 573 "notNull": true 574 }, 575 "parent_uri": { 576 "name": "parent_uri", 577 "type": "text", 578 "primaryKey": false, 579 "notNull": true 580 }, 581 "parent_cid": { 582 "name": "parent_cid", 583 "type": "text", 584 "primaryKey": false, 585 "notNull": true 586 }, 587 "community_did": { 588 "name": "community_did", 589 "type": "text", 590 "primaryKey": false, 591 "notNull": true 592 }, 593 "cid": { 594 "name": "cid", 595 "type": "text", 596 "primaryKey": false, 597 "notNull": true 598 }, 599 "labels": { 600 "name": "labels", 601 "type": "jsonb", 602 "primaryKey": false, 603 "notNull": false 604 }, 605 "reaction_count": { 606 "name": "reaction_count", 607 "type": "integer", 608 "primaryKey": false, 609 "notNull": true, 610 "default": 0 611 }, 612 "vote_count": { 613 "name": "vote_count", 614 "type": "integer", 615 "primaryKey": false, 616 "notNull": true, 617 "default": 0 618 }, 619 "created_at": { 620 "name": "created_at", 621 "type": "timestamp with time zone", 622 "primaryKey": false, 623 "notNull": true 624 }, 625 "indexed_at": { 626 "name": "indexed_at", 627 "type": "timestamp with time zone", 628 "primaryKey": false, 629 "notNull": true, 630 "default": "now()" 631 }, 632 "is_author_deleted": { 633 "name": "is_author_deleted", 634 "type": "boolean", 635 "primaryKey": false, 636 "notNull": true, 637 "default": false 638 }, 639 "is_mod_deleted": { 640 "name": "is_mod_deleted", 641 "type": "boolean", 642 "primaryKey": false, 643 "notNull": true, 644 "default": false 645 }, 646 "moderation_status": { 647 "name": "moderation_status", 648 "type": "text", 649 "primaryKey": false, 650 "notNull": true, 651 "default": "'approved'" 652 }, 653 "trust_status": { 654 "name": "trust_status", 655 "type": "text", 656 "primaryKey": false, 657 "notNull": true, 658 "default": "'trusted'" 659 } 660 }, 661 "indexes": { 662 "replies_author_did_idx": { 663 "name": "replies_author_did_idx", 664 "columns": [ 665 { 666 "expression": "author_did", 667 "isExpression": false, 668 "asc": true, 669 "nulls": "last" 670 } 671 ], 672 "isUnique": false, 673 "concurrently": false, 674 "method": "btree", 675 "with": {} 676 }, 677 "replies_root_uri_idx": { 678 "name": "replies_root_uri_idx", 679 "columns": [ 680 { 681 "expression": "root_uri", 682 "isExpression": false, 683 "asc": true, 684 "nulls": "last" 685 } 686 ], 687 "isUnique": false, 688 "concurrently": false, 689 "method": "btree", 690 "with": {} 691 }, 692 "replies_parent_uri_idx": { 693 "name": "replies_parent_uri_idx", 694 "columns": [ 695 { 696 "expression": "parent_uri", 697 "isExpression": false, 698 "asc": true, 699 "nulls": "last" 700 } 701 ], 702 "isUnique": false, 703 "concurrently": false, 704 "method": "btree", 705 "with": {} 706 }, 707 "replies_created_at_idx": { 708 "name": "replies_created_at_idx", 709 "columns": [ 710 { 711 "expression": "created_at", 712 "isExpression": false, 713 "asc": true, 714 "nulls": "last" 715 } 716 ], 717 "isUnique": false, 718 "concurrently": false, 719 "method": "btree", 720 "with": {} 721 }, 722 "replies_community_did_idx": { 723 "name": "replies_community_did_idx", 724 "columns": [ 725 { 726 "expression": "community_did", 727 "isExpression": false, 728 "asc": true, 729 "nulls": "last" 730 } 731 ], 732 "isUnique": false, 733 "concurrently": false, 734 "method": "btree", 735 "with": {} 736 }, 737 "replies_moderation_status_idx": { 738 "name": "replies_moderation_status_idx", 739 "columns": [ 740 { 741 "expression": "moderation_status", 742 "isExpression": false, 743 "asc": true, 744 "nulls": "last" 745 } 746 ], 747 "isUnique": false, 748 "concurrently": false, 749 "method": "btree", 750 "with": {} 751 }, 752 "replies_trust_status_idx": { 753 "name": "replies_trust_status_idx", 754 "columns": [ 755 { 756 "expression": "trust_status", 757 "isExpression": false, 758 "asc": true, 759 "nulls": "last" 760 } 761 ], 762 "isUnique": false, 763 "concurrently": false, 764 "method": "btree", 765 "with": {} 766 }, 767 "replies_root_uri_created_at_idx": { 768 "name": "replies_root_uri_created_at_idx", 769 "columns": [ 770 { 771 "expression": "root_uri", 772 "isExpression": false, 773 "asc": true, 774 "nulls": "last" 775 }, 776 { 777 "expression": "created_at", 778 "isExpression": false, 779 "asc": true, 780 "nulls": "last" 781 } 782 ], 783 "isUnique": false, 784 "concurrently": false, 785 "method": "btree", 786 "with": {} 787 } 788 }, 789 "foreignKeys": {}, 790 "compositePrimaryKeys": {}, 791 "uniqueConstraints": {}, 792 "policies": { 793 "tenant_isolation": { 794 "name": "tenant_isolation", 795 "as": "PERMISSIVE", 796 "for": "ALL", 797 "to": ["barazo_app"], 798 "using": "community_did = current_setting('app.current_community_did', true)", 799 "withCheck": "community_did = current_setting('app.current_community_did', true)" 800 } 801 }, 802 "checkConstraints": {}, 803 "isRLSEnabled": true 804 }, 805 "public.reactions": { 806 "name": "reactions", 807 "schema": "", 808 "columns": { 809 "uri": { 810 "name": "uri", 811 "type": "text", 812 "primaryKey": true, 813 "notNull": true 814 }, 815 "rkey": { 816 "name": "rkey", 817 "type": "text", 818 "primaryKey": false, 819 "notNull": true 820 }, 821 "author_did": { 822 "name": "author_did", 823 "type": "text", 824 "primaryKey": false, 825 "notNull": true 826 }, 827 "subject_uri": { 828 "name": "subject_uri", 829 "type": "text", 830 "primaryKey": false, 831 "notNull": true 832 }, 833 "subject_cid": { 834 "name": "subject_cid", 835 "type": "text", 836 "primaryKey": false, 837 "notNull": true 838 }, 839 "type": { 840 "name": "type", 841 "type": "text", 842 "primaryKey": false, 843 "notNull": true 844 }, 845 "community_did": { 846 "name": "community_did", 847 "type": "text", 848 "primaryKey": false, 849 "notNull": true 850 }, 851 "cid": { 852 "name": "cid", 853 "type": "text", 854 "primaryKey": false, 855 "notNull": true 856 }, 857 "created_at": { 858 "name": "created_at", 859 "type": "timestamp with time zone", 860 "primaryKey": false, 861 "notNull": true 862 }, 863 "indexed_at": { 864 "name": "indexed_at", 865 "type": "timestamp with time zone", 866 "primaryKey": false, 867 "notNull": true, 868 "default": "now()" 869 } 870 }, 871 "indexes": { 872 "reactions_author_did_idx": { 873 "name": "reactions_author_did_idx", 874 "columns": [ 875 { 876 "expression": "author_did", 877 "isExpression": false, 878 "asc": true, 879 "nulls": "last" 880 } 881 ], 882 "isUnique": false, 883 "concurrently": false, 884 "method": "btree", 885 "with": {} 886 }, 887 "reactions_subject_uri_idx": { 888 "name": "reactions_subject_uri_idx", 889 "columns": [ 890 { 891 "expression": "subject_uri", 892 "isExpression": false, 893 "asc": true, 894 "nulls": "last" 895 } 896 ], 897 "isUnique": false, 898 "concurrently": false, 899 "method": "btree", 900 "with": {} 901 }, 902 "reactions_community_did_idx": { 903 "name": "reactions_community_did_idx", 904 "columns": [ 905 { 906 "expression": "community_did", 907 "isExpression": false, 908 "asc": true, 909 "nulls": "last" 910 } 911 ], 912 "isUnique": false, 913 "concurrently": false, 914 "method": "btree", 915 "with": {} 916 }, 917 "reactions_subject_uri_type_idx": { 918 "name": "reactions_subject_uri_type_idx", 919 "columns": [ 920 { 921 "expression": "subject_uri", 922 "isExpression": false, 923 "asc": true, 924 "nulls": "last" 925 }, 926 { 927 "expression": "type", 928 "isExpression": false, 929 "asc": true, 930 "nulls": "last" 931 } 932 ], 933 "isUnique": false, 934 "concurrently": false, 935 "method": "btree", 936 "with": {} 937 } 938 }, 939 "foreignKeys": {}, 940 "compositePrimaryKeys": {}, 941 "uniqueConstraints": { 942 "reactions_author_subject_type_uniq": { 943 "name": "reactions_author_subject_type_uniq", 944 "nullsNotDistinct": false, 945 "columns": ["author_did", "subject_uri", "type"] 946 } 947 }, 948 "policies": { 949 "tenant_isolation": { 950 "name": "tenant_isolation", 951 "as": "PERMISSIVE", 952 "for": "ALL", 953 "to": ["barazo_app"], 954 "using": "community_did = current_setting('app.current_community_did', true)", 955 "withCheck": "community_did = current_setting('app.current_community_did', true)" 956 } 957 }, 958 "checkConstraints": {}, 959 "isRLSEnabled": true 960 }, 961 "public.votes": { 962 "name": "votes", 963 "schema": "", 964 "columns": { 965 "uri": { 966 "name": "uri", 967 "type": "text", 968 "primaryKey": true, 969 "notNull": true 970 }, 971 "rkey": { 972 "name": "rkey", 973 "type": "text", 974 "primaryKey": false, 975 "notNull": true 976 }, 977 "author_did": { 978 "name": "author_did", 979 "type": "text", 980 "primaryKey": false, 981 "notNull": true 982 }, 983 "subject_uri": { 984 "name": "subject_uri", 985 "type": "text", 986 "primaryKey": false, 987 "notNull": true 988 }, 989 "subject_cid": { 990 "name": "subject_cid", 991 "type": "text", 992 "primaryKey": false, 993 "notNull": true 994 }, 995 "direction": { 996 "name": "direction", 997 "type": "text", 998 "primaryKey": false, 999 "notNull": true 1000 }, 1001 "community_did": { 1002 "name": "community_did", 1003 "type": "text", 1004 "primaryKey": false, 1005 "notNull": true 1006 }, 1007 "cid": { 1008 "name": "cid", 1009 "type": "text", 1010 "primaryKey": false, 1011 "notNull": true 1012 }, 1013 "created_at": { 1014 "name": "created_at", 1015 "type": "timestamp with time zone", 1016 "primaryKey": false, 1017 "notNull": true 1018 }, 1019 "indexed_at": { 1020 "name": "indexed_at", 1021 "type": "timestamp with time zone", 1022 "primaryKey": false, 1023 "notNull": true, 1024 "default": "now()" 1025 } 1026 }, 1027 "indexes": { 1028 "votes_author_did_idx": { 1029 "name": "votes_author_did_idx", 1030 "columns": [ 1031 { 1032 "expression": "author_did", 1033 "isExpression": false, 1034 "asc": true, 1035 "nulls": "last" 1036 } 1037 ], 1038 "isUnique": false, 1039 "concurrently": false, 1040 "method": "btree", 1041 "with": {} 1042 }, 1043 "votes_subject_uri_idx": { 1044 "name": "votes_subject_uri_idx", 1045 "columns": [ 1046 { 1047 "expression": "subject_uri", 1048 "isExpression": false, 1049 "asc": true, 1050 "nulls": "last" 1051 } 1052 ], 1053 "isUnique": false, 1054 "concurrently": false, 1055 "method": "btree", 1056 "with": {} 1057 }, 1058 "votes_community_did_idx": { 1059 "name": "votes_community_did_idx", 1060 "columns": [ 1061 { 1062 "expression": "community_did", 1063 "isExpression": false, 1064 "asc": true, 1065 "nulls": "last" 1066 } 1067 ], 1068 "isUnique": false, 1069 "concurrently": false, 1070 "method": "btree", 1071 "with": {} 1072 } 1073 }, 1074 "foreignKeys": {}, 1075 "compositePrimaryKeys": {}, 1076 "uniqueConstraints": { 1077 "votes_author_subject_uniq": { 1078 "name": "votes_author_subject_uniq", 1079 "nullsNotDistinct": false, 1080 "columns": ["author_did", "subject_uri"] 1081 } 1082 }, 1083 "policies": {}, 1084 "checkConstraints": {}, 1085 "isRLSEnabled": false 1086 }, 1087 "public.tracked_repos": { 1088 "name": "tracked_repos", 1089 "schema": "", 1090 "columns": { 1091 "did": { 1092 "name": "did", 1093 "type": "text", 1094 "primaryKey": true, 1095 "notNull": true 1096 }, 1097 "tracked_at": { 1098 "name": "tracked_at", 1099 "type": "timestamp with time zone", 1100 "primaryKey": false, 1101 "notNull": true, 1102 "default": "now()" 1103 } 1104 }, 1105 "indexes": {}, 1106 "foreignKeys": {}, 1107 "compositePrimaryKeys": {}, 1108 "uniqueConstraints": {}, 1109 "policies": {}, 1110 "checkConstraints": {}, 1111 "isRLSEnabled": false 1112 }, 1113 "public.community_settings": { 1114 "name": "community_settings", 1115 "schema": "", 1116 "columns": { 1117 "community_did": { 1118 "name": "community_did", 1119 "type": "text", 1120 "primaryKey": true, 1121 "notNull": true 1122 }, 1123 "domains": { 1124 "name": "domains", 1125 "type": "jsonb", 1126 "primaryKey": false, 1127 "notNull": true, 1128 "default": "'[]'::jsonb" 1129 }, 1130 "initialized": { 1131 "name": "initialized", 1132 "type": "boolean", 1133 "primaryKey": false, 1134 "notNull": true, 1135 "default": false 1136 }, 1137 "admin_did": { 1138 "name": "admin_did", 1139 "type": "text", 1140 "primaryKey": false, 1141 "notNull": false 1142 }, 1143 "community_name": { 1144 "name": "community_name", 1145 "type": "text", 1146 "primaryKey": false, 1147 "notNull": true, 1148 "default": "'Barazo Community'" 1149 }, 1150 "maturity_rating": { 1151 "name": "maturity_rating", 1152 "type": "text", 1153 "primaryKey": false, 1154 "notNull": true, 1155 "default": "'safe'" 1156 }, 1157 "reaction_set": { 1158 "name": "reaction_set", 1159 "type": "jsonb", 1160 "primaryKey": false, 1161 "notNull": true, 1162 "default": "'[\"like\"]'::jsonb" 1163 }, 1164 "moderation_thresholds": { 1165 "name": "moderation_thresholds", 1166 "type": "jsonb", 1167 "primaryKey": false, 1168 "notNull": true, 1169 "default": "'{\"autoBlockReportCount\":5,\"warnThreshold\":3,\"firstPostQueueCount\":3,\"newAccountDays\":7,\"newAccountWriteRatePerMin\":3,\"establishedWriteRatePerMin\":10,\"linkHoldEnabled\":true,\"topicCreationDelayEnabled\":true,\"burstPostCount\":5,\"burstWindowMinutes\":10,\"trustedPostThreshold\":10}'::jsonb" 1170 }, 1171 "word_filter": { 1172 "name": "word_filter", 1173 "type": "jsonb", 1174 "primaryKey": false, 1175 "notNull": true, 1176 "default": "'[]'::jsonb" 1177 }, 1178 "jurisdiction_country": { 1179 "name": "jurisdiction_country", 1180 "type": "text", 1181 "primaryKey": false, 1182 "notNull": false 1183 }, 1184 "age_threshold": { 1185 "name": "age_threshold", 1186 "type": "integer", 1187 "primaryKey": false, 1188 "notNull": true, 1189 "default": 16 1190 }, 1191 "require_login_for_mature": { 1192 "name": "require_login_for_mature", 1193 "type": "boolean", 1194 "primaryKey": false, 1195 "notNull": true, 1196 "default": true 1197 }, 1198 "community_description": { 1199 "name": "community_description", 1200 "type": "text", 1201 "primaryKey": false, 1202 "notNull": false 1203 }, 1204 "handle": { 1205 "name": "handle", 1206 "type": "text", 1207 "primaryKey": false, 1208 "notNull": false 1209 }, 1210 "service_endpoint": { 1211 "name": "service_endpoint", 1212 "type": "text", 1213 "primaryKey": false, 1214 "notNull": false 1215 }, 1216 "signing_key": { 1217 "name": "signing_key", 1218 "type": "text", 1219 "primaryKey": false, 1220 "notNull": false 1221 }, 1222 "rotation_key": { 1223 "name": "rotation_key", 1224 "type": "text", 1225 "primaryKey": false, 1226 "notNull": false 1227 }, 1228 "community_logo_url": { 1229 "name": "community_logo_url", 1230 "type": "text", 1231 "primaryKey": false, 1232 "notNull": false 1233 }, 1234 "primary_color": { 1235 "name": "primary_color", 1236 "type": "text", 1237 "primaryKey": false, 1238 "notNull": false 1239 }, 1240 "accent_color": { 1241 "name": "accent_color", 1242 "type": "text", 1243 "primaryKey": false, 1244 "notNull": false 1245 }, 1246 "created_at": { 1247 "name": "created_at", 1248 "type": "timestamp with time zone", 1249 "primaryKey": false, 1250 "notNull": true, 1251 "default": "now()" 1252 }, 1253 "updated_at": { 1254 "name": "updated_at", 1255 "type": "timestamp with time zone", 1256 "primaryKey": false, 1257 "notNull": true, 1258 "default": "now()" 1259 } 1260 }, 1261 "indexes": {}, 1262 "foreignKeys": {}, 1263 "compositePrimaryKeys": {}, 1264 "uniqueConstraints": {}, 1265 "policies": { 1266 "tenant_isolation": { 1267 "name": "tenant_isolation", 1268 "as": "PERMISSIVE", 1269 "for": "ALL", 1270 "to": ["barazo_app"], 1271 "using": "community_did = current_setting('app.current_community_did', true)", 1272 "withCheck": "community_did = current_setting('app.current_community_did', true)" 1273 } 1274 }, 1275 "checkConstraints": {}, 1276 "isRLSEnabled": true 1277 }, 1278 "public.categories": { 1279 "name": "categories", 1280 "schema": "", 1281 "columns": { 1282 "id": { 1283 "name": "id", 1284 "type": "text", 1285 "primaryKey": true, 1286 "notNull": true 1287 }, 1288 "slug": { 1289 "name": "slug", 1290 "type": "text", 1291 "primaryKey": false, 1292 "notNull": true 1293 }, 1294 "name": { 1295 "name": "name", 1296 "type": "text", 1297 "primaryKey": false, 1298 "notNull": true 1299 }, 1300 "description": { 1301 "name": "description", 1302 "type": "text", 1303 "primaryKey": false, 1304 "notNull": false 1305 }, 1306 "parent_id": { 1307 "name": "parent_id", 1308 "type": "text", 1309 "primaryKey": false, 1310 "notNull": false 1311 }, 1312 "sort_order": { 1313 "name": "sort_order", 1314 "type": "integer", 1315 "primaryKey": false, 1316 "notNull": true, 1317 "default": 0 1318 }, 1319 "community_did": { 1320 "name": "community_did", 1321 "type": "text", 1322 "primaryKey": false, 1323 "notNull": true 1324 }, 1325 "maturity_rating": { 1326 "name": "maturity_rating", 1327 "type": "text", 1328 "primaryKey": false, 1329 "notNull": true, 1330 "default": "'safe'" 1331 }, 1332 "created_at": { 1333 "name": "created_at", 1334 "type": "timestamp with time zone", 1335 "primaryKey": false, 1336 "notNull": true, 1337 "default": "now()" 1338 }, 1339 "updated_at": { 1340 "name": "updated_at", 1341 "type": "timestamp with time zone", 1342 "primaryKey": false, 1343 "notNull": true, 1344 "default": "now()" 1345 } 1346 }, 1347 "indexes": { 1348 "categories_slug_community_did_idx": { 1349 "name": "categories_slug_community_did_idx", 1350 "columns": [ 1351 { 1352 "expression": "slug", 1353 "isExpression": false, 1354 "asc": true, 1355 "nulls": "last" 1356 }, 1357 { 1358 "expression": "community_did", 1359 "isExpression": false, 1360 "asc": true, 1361 "nulls": "last" 1362 } 1363 ], 1364 "isUnique": true, 1365 "concurrently": false, 1366 "method": "btree", 1367 "with": {} 1368 }, 1369 "categories_parent_id_idx": { 1370 "name": "categories_parent_id_idx", 1371 "columns": [ 1372 { 1373 "expression": "parent_id", 1374 "isExpression": false, 1375 "asc": true, 1376 "nulls": "last" 1377 } 1378 ], 1379 "isUnique": false, 1380 "concurrently": false, 1381 "method": "btree", 1382 "with": {} 1383 }, 1384 "categories_community_did_idx": { 1385 "name": "categories_community_did_idx", 1386 "columns": [ 1387 { 1388 "expression": "community_did", 1389 "isExpression": false, 1390 "asc": true, 1391 "nulls": "last" 1392 } 1393 ], 1394 "isUnique": false, 1395 "concurrently": false, 1396 "method": "btree", 1397 "with": {} 1398 }, 1399 "categories_maturity_rating_idx": { 1400 "name": "categories_maturity_rating_idx", 1401 "columns": [ 1402 { 1403 "expression": "maturity_rating", 1404 "isExpression": false, 1405 "asc": true, 1406 "nulls": "last" 1407 } 1408 ], 1409 "isUnique": false, 1410 "concurrently": false, 1411 "method": "btree", 1412 "with": {} 1413 } 1414 }, 1415 "foreignKeys": { 1416 "categories_parent_id_fk": { 1417 "name": "categories_parent_id_fk", 1418 "tableFrom": "categories", 1419 "tableTo": "categories", 1420 "columnsFrom": ["parent_id"], 1421 "columnsTo": ["id"], 1422 "onDelete": "set null", 1423 "onUpdate": "no action" 1424 } 1425 }, 1426 "compositePrimaryKeys": {}, 1427 "uniqueConstraints": {}, 1428 "policies": { 1429 "tenant_isolation": { 1430 "name": "tenant_isolation", 1431 "as": "PERMISSIVE", 1432 "for": "ALL", 1433 "to": ["barazo_app"], 1434 "using": "community_did = current_setting('app.current_community_did', true)", 1435 "withCheck": "community_did = current_setting('app.current_community_did', true)" 1436 } 1437 }, 1438 "checkConstraints": {}, 1439 "isRLSEnabled": true 1440 }, 1441 "public.moderation_actions": { 1442 "name": "moderation_actions", 1443 "schema": "", 1444 "columns": { 1445 "id": { 1446 "name": "id", 1447 "type": "serial", 1448 "primaryKey": true, 1449 "notNull": true 1450 }, 1451 "action": { 1452 "name": "action", 1453 "type": "text", 1454 "primaryKey": false, 1455 "notNull": true 1456 }, 1457 "target_uri": { 1458 "name": "target_uri", 1459 "type": "text", 1460 "primaryKey": false, 1461 "notNull": false 1462 }, 1463 "target_did": { 1464 "name": "target_did", 1465 "type": "text", 1466 "primaryKey": false, 1467 "notNull": false 1468 }, 1469 "moderator_did": { 1470 "name": "moderator_did", 1471 "type": "text", 1472 "primaryKey": false, 1473 "notNull": true 1474 }, 1475 "community_did": { 1476 "name": "community_did", 1477 "type": "text", 1478 "primaryKey": false, 1479 "notNull": true 1480 }, 1481 "reason": { 1482 "name": "reason", 1483 "type": "text", 1484 "primaryKey": false, 1485 "notNull": false 1486 }, 1487 "created_at": { 1488 "name": "created_at", 1489 "type": "timestamp with time zone", 1490 "primaryKey": false, 1491 "notNull": true, 1492 "default": "now()" 1493 } 1494 }, 1495 "indexes": { 1496 "mod_actions_moderator_did_idx": { 1497 "name": "mod_actions_moderator_did_idx", 1498 "columns": [ 1499 { 1500 "expression": "moderator_did", 1501 "isExpression": false, 1502 "asc": true, 1503 "nulls": "last" 1504 } 1505 ], 1506 "isUnique": false, 1507 "concurrently": false, 1508 "method": "btree", 1509 "with": {} 1510 }, 1511 "mod_actions_community_did_idx": { 1512 "name": "mod_actions_community_did_idx", 1513 "columns": [ 1514 { 1515 "expression": "community_did", 1516 "isExpression": false, 1517 "asc": true, 1518 "nulls": "last" 1519 } 1520 ], 1521 "isUnique": false, 1522 "concurrently": false, 1523 "method": "btree", 1524 "with": {} 1525 }, 1526 "mod_actions_created_at_idx": { 1527 "name": "mod_actions_created_at_idx", 1528 "columns": [ 1529 { 1530 "expression": "created_at", 1531 "isExpression": false, 1532 "asc": true, 1533 "nulls": "last" 1534 } 1535 ], 1536 "isUnique": false, 1537 "concurrently": false, 1538 "method": "btree", 1539 "with": {} 1540 }, 1541 "mod_actions_target_uri_idx": { 1542 "name": "mod_actions_target_uri_idx", 1543 "columns": [ 1544 { 1545 "expression": "target_uri", 1546 "isExpression": false, 1547 "asc": true, 1548 "nulls": "last" 1549 } 1550 ], 1551 "isUnique": false, 1552 "concurrently": false, 1553 "method": "btree", 1554 "with": {} 1555 }, 1556 "mod_actions_target_did_idx": { 1557 "name": "mod_actions_target_did_idx", 1558 "columns": [ 1559 { 1560 "expression": "target_did", 1561 "isExpression": false, 1562 "asc": true, 1563 "nulls": "last" 1564 } 1565 ], 1566 "isUnique": false, 1567 "concurrently": false, 1568 "method": "btree", 1569 "with": {} 1570 } 1571 }, 1572 "foreignKeys": {}, 1573 "compositePrimaryKeys": {}, 1574 "uniqueConstraints": {}, 1575 "policies": { 1576 "tenant_isolation": { 1577 "name": "tenant_isolation", 1578 "as": "PERMISSIVE", 1579 "for": "ALL", 1580 "to": ["barazo_app"], 1581 "using": "community_did = current_setting('app.current_community_did', true)", 1582 "withCheck": "community_did = current_setting('app.current_community_did', true)" 1583 } 1584 }, 1585 "checkConstraints": {}, 1586 "isRLSEnabled": true 1587 }, 1588 "public.reports": { 1589 "name": "reports", 1590 "schema": "", 1591 "columns": { 1592 "id": { 1593 "name": "id", 1594 "type": "serial", 1595 "primaryKey": true, 1596 "notNull": true 1597 }, 1598 "reporter_did": { 1599 "name": "reporter_did", 1600 "type": "text", 1601 "primaryKey": false, 1602 "notNull": true 1603 }, 1604 "target_uri": { 1605 "name": "target_uri", 1606 "type": "text", 1607 "primaryKey": false, 1608 "notNull": true 1609 }, 1610 "target_did": { 1611 "name": "target_did", 1612 "type": "text", 1613 "primaryKey": false, 1614 "notNull": true 1615 }, 1616 "reason_type": { 1617 "name": "reason_type", 1618 "type": "text", 1619 "primaryKey": false, 1620 "notNull": true 1621 }, 1622 "description": { 1623 "name": "description", 1624 "type": "text", 1625 "primaryKey": false, 1626 "notNull": false 1627 }, 1628 "community_did": { 1629 "name": "community_did", 1630 "type": "text", 1631 "primaryKey": false, 1632 "notNull": true 1633 }, 1634 "status": { 1635 "name": "status", 1636 "type": "text", 1637 "primaryKey": false, 1638 "notNull": true, 1639 "default": "'pending'" 1640 }, 1641 "resolution_type": { 1642 "name": "resolution_type", 1643 "type": "text", 1644 "primaryKey": false, 1645 "notNull": false 1646 }, 1647 "resolved_by": { 1648 "name": "resolved_by", 1649 "type": "text", 1650 "primaryKey": false, 1651 "notNull": false 1652 }, 1653 "resolved_at": { 1654 "name": "resolved_at", 1655 "type": "timestamp with time zone", 1656 "primaryKey": false, 1657 "notNull": false 1658 }, 1659 "appeal_reason": { 1660 "name": "appeal_reason", 1661 "type": "text", 1662 "primaryKey": false, 1663 "notNull": false 1664 }, 1665 "appealed_at": { 1666 "name": "appealed_at", 1667 "type": "timestamp with time zone", 1668 "primaryKey": false, 1669 "notNull": false 1670 }, 1671 "appeal_status": { 1672 "name": "appeal_status", 1673 "type": "text", 1674 "primaryKey": false, 1675 "notNull": true, 1676 "default": "'none'" 1677 }, 1678 "created_at": { 1679 "name": "created_at", 1680 "type": "timestamp with time zone", 1681 "primaryKey": false, 1682 "notNull": true, 1683 "default": "now()" 1684 } 1685 }, 1686 "indexes": { 1687 "reports_reporter_did_idx": { 1688 "name": "reports_reporter_did_idx", 1689 "columns": [ 1690 { 1691 "expression": "reporter_did", 1692 "isExpression": false, 1693 "asc": true, 1694 "nulls": "last" 1695 } 1696 ], 1697 "isUnique": false, 1698 "concurrently": false, 1699 "method": "btree", 1700 "with": {} 1701 }, 1702 "reports_target_uri_idx": { 1703 "name": "reports_target_uri_idx", 1704 "columns": [ 1705 { 1706 "expression": "target_uri", 1707 "isExpression": false, 1708 "asc": true, 1709 "nulls": "last" 1710 } 1711 ], 1712 "isUnique": false, 1713 "concurrently": false, 1714 "method": "btree", 1715 "with": {} 1716 }, 1717 "reports_target_did_idx": { 1718 "name": "reports_target_did_idx", 1719 "columns": [ 1720 { 1721 "expression": "target_did", 1722 "isExpression": false, 1723 "asc": true, 1724 "nulls": "last" 1725 } 1726 ], 1727 "isUnique": false, 1728 "concurrently": false, 1729 "method": "btree", 1730 "with": {} 1731 }, 1732 "reports_community_did_idx": { 1733 "name": "reports_community_did_idx", 1734 "columns": [ 1735 { 1736 "expression": "community_did", 1737 "isExpression": false, 1738 "asc": true, 1739 "nulls": "last" 1740 } 1741 ], 1742 "isUnique": false, 1743 "concurrently": false, 1744 "method": "btree", 1745 "with": {} 1746 }, 1747 "reports_status_idx": { 1748 "name": "reports_status_idx", 1749 "columns": [ 1750 { 1751 "expression": "status", 1752 "isExpression": false, 1753 "asc": true, 1754 "nulls": "last" 1755 } 1756 ], 1757 "isUnique": false, 1758 "concurrently": false, 1759 "method": "btree", 1760 "with": {} 1761 }, 1762 "reports_created_at_idx": { 1763 "name": "reports_created_at_idx", 1764 "columns": [ 1765 { 1766 "expression": "created_at", 1767 "isExpression": false, 1768 "asc": true, 1769 "nulls": "last" 1770 } 1771 ], 1772 "isUnique": false, 1773 "concurrently": false, 1774 "method": "btree", 1775 "with": {} 1776 }, 1777 "reports_unique_reporter_target_idx": { 1778 "name": "reports_unique_reporter_target_idx", 1779 "columns": [ 1780 { 1781 "expression": "reporter_did", 1782 "isExpression": false, 1783 "asc": true, 1784 "nulls": "last" 1785 }, 1786 { 1787 "expression": "target_uri", 1788 "isExpression": false, 1789 "asc": true, 1790 "nulls": "last" 1791 }, 1792 { 1793 "expression": "community_did", 1794 "isExpression": false, 1795 "asc": true, 1796 "nulls": "last" 1797 } 1798 ], 1799 "isUnique": true, 1800 "concurrently": false, 1801 "method": "btree", 1802 "with": {} 1803 } 1804 }, 1805 "foreignKeys": {}, 1806 "compositePrimaryKeys": {}, 1807 "uniqueConstraints": {}, 1808 "policies": { 1809 "tenant_isolation": { 1810 "name": "tenant_isolation", 1811 "as": "PERMISSIVE", 1812 "for": "ALL", 1813 "to": ["barazo_app"], 1814 "using": "community_did = current_setting('app.current_community_did', true)", 1815 "withCheck": "community_did = current_setting('app.current_community_did', true)" 1816 } 1817 }, 1818 "checkConstraints": {}, 1819 "isRLSEnabled": true 1820 }, 1821 "public.notifications": { 1822 "name": "notifications", 1823 "schema": "", 1824 "columns": { 1825 "id": { 1826 "name": "id", 1827 "type": "serial", 1828 "primaryKey": true, 1829 "notNull": true 1830 }, 1831 "recipient_did": { 1832 "name": "recipient_did", 1833 "type": "text", 1834 "primaryKey": false, 1835 "notNull": true 1836 }, 1837 "type": { 1838 "name": "type", 1839 "type": "text", 1840 "primaryKey": false, 1841 "notNull": true 1842 }, 1843 "subject_uri": { 1844 "name": "subject_uri", 1845 "type": "text", 1846 "primaryKey": false, 1847 "notNull": true 1848 }, 1849 "actor_did": { 1850 "name": "actor_did", 1851 "type": "text", 1852 "primaryKey": false, 1853 "notNull": true 1854 }, 1855 "community_did": { 1856 "name": "community_did", 1857 "type": "text", 1858 "primaryKey": false, 1859 "notNull": true 1860 }, 1861 "read": { 1862 "name": "read", 1863 "type": "boolean", 1864 "primaryKey": false, 1865 "notNull": true, 1866 "default": false 1867 }, 1868 "created_at": { 1869 "name": "created_at", 1870 "type": "timestamp with time zone", 1871 "primaryKey": false, 1872 "notNull": true, 1873 "default": "now()" 1874 } 1875 }, 1876 "indexes": { 1877 "notifications_recipient_did_idx": { 1878 "name": "notifications_recipient_did_idx", 1879 "columns": [ 1880 { 1881 "expression": "recipient_did", 1882 "isExpression": false, 1883 "asc": true, 1884 "nulls": "last" 1885 } 1886 ], 1887 "isUnique": false, 1888 "concurrently": false, 1889 "method": "btree", 1890 "with": {} 1891 }, 1892 "notifications_recipient_read_idx": { 1893 "name": "notifications_recipient_read_idx", 1894 "columns": [ 1895 { 1896 "expression": "recipient_did", 1897 "isExpression": false, 1898 "asc": true, 1899 "nulls": "last" 1900 }, 1901 { 1902 "expression": "read", 1903 "isExpression": false, 1904 "asc": true, 1905 "nulls": "last" 1906 } 1907 ], 1908 "isUnique": false, 1909 "concurrently": false, 1910 "method": "btree", 1911 "with": {} 1912 }, 1913 "notifications_created_at_idx": { 1914 "name": "notifications_created_at_idx", 1915 "columns": [ 1916 { 1917 "expression": "created_at", 1918 "isExpression": false, 1919 "asc": true, 1920 "nulls": "last" 1921 } 1922 ], 1923 "isUnique": false, 1924 "concurrently": false, 1925 "method": "btree", 1926 "with": {} 1927 } 1928 }, 1929 "foreignKeys": {}, 1930 "compositePrimaryKeys": {}, 1931 "uniqueConstraints": {}, 1932 "policies": { 1933 "tenant_isolation": { 1934 "name": "tenant_isolation", 1935 "as": "PERMISSIVE", 1936 "for": "ALL", 1937 "to": ["barazo_app"], 1938 "using": "community_did = current_setting('app.current_community_did', true)", 1939 "withCheck": "community_did = current_setting('app.current_community_did', true)" 1940 } 1941 }, 1942 "checkConstraints": {}, 1943 "isRLSEnabled": true 1944 }, 1945 "public.user_community_preferences": { 1946 "name": "user_community_preferences", 1947 "schema": "", 1948 "columns": { 1949 "did": { 1950 "name": "did", 1951 "type": "text", 1952 "primaryKey": false, 1953 "notNull": true 1954 }, 1955 "community_did": { 1956 "name": "community_did", 1957 "type": "text", 1958 "primaryKey": false, 1959 "notNull": true 1960 }, 1961 "maturity_override": { 1962 "name": "maturity_override", 1963 "type": "text", 1964 "primaryKey": false, 1965 "notNull": false 1966 }, 1967 "muted_words": { 1968 "name": "muted_words", 1969 "type": "jsonb", 1970 "primaryKey": false, 1971 "notNull": false 1972 }, 1973 "blocked_dids": { 1974 "name": "blocked_dids", 1975 "type": "jsonb", 1976 "primaryKey": false, 1977 "notNull": false 1978 }, 1979 "muted_dids": { 1980 "name": "muted_dids", 1981 "type": "jsonb", 1982 "primaryKey": false, 1983 "notNull": false 1984 }, 1985 "notification_prefs": { 1986 "name": "notification_prefs", 1987 "type": "jsonb", 1988 "primaryKey": false, 1989 "notNull": false 1990 }, 1991 "updated_at": { 1992 "name": "updated_at", 1993 "type": "timestamp with time zone", 1994 "primaryKey": false, 1995 "notNull": true, 1996 "default": "now()" 1997 } 1998 }, 1999 "indexes": { 2000 "user_community_prefs_did_idx": { 2001 "name": "user_community_prefs_did_idx", 2002 "columns": [ 2003 { 2004 "expression": "did", 2005 "isExpression": false, 2006 "asc": true, 2007 "nulls": "last" 2008 } 2009 ], 2010 "isUnique": false, 2011 "concurrently": false, 2012 "method": "btree", 2013 "with": {} 2014 }, 2015 "user_community_prefs_community_idx": { 2016 "name": "user_community_prefs_community_idx", 2017 "columns": [ 2018 { 2019 "expression": "community_did", 2020 "isExpression": false, 2021 "asc": true, 2022 "nulls": "last" 2023 } 2024 ], 2025 "isUnique": false, 2026 "concurrently": false, 2027 "method": "btree", 2028 "with": {} 2029 } 2030 }, 2031 "foreignKeys": {}, 2032 "compositePrimaryKeys": { 2033 "user_community_preferences_did_community_did_pk": { 2034 "name": "user_community_preferences_did_community_did_pk", 2035 "columns": ["did", "community_did"] 2036 } 2037 }, 2038 "uniqueConstraints": {}, 2039 "policies": { 2040 "tenant_isolation": { 2041 "name": "tenant_isolation", 2042 "as": "PERMISSIVE", 2043 "for": "ALL", 2044 "to": ["barazo_app"], 2045 "using": "community_did = current_setting('app.current_community_did', true)", 2046 "withCheck": "community_did = current_setting('app.current_community_did', true)" 2047 } 2048 }, 2049 "checkConstraints": {}, 2050 "isRLSEnabled": true 2051 }, 2052 "public.user_preferences": { 2053 "name": "user_preferences", 2054 "schema": "", 2055 "columns": { 2056 "did": { 2057 "name": "did", 2058 "type": "text", 2059 "primaryKey": true, 2060 "notNull": true 2061 }, 2062 "maturity_level": { 2063 "name": "maturity_level", 2064 "type": "text", 2065 "primaryKey": false, 2066 "notNull": true, 2067 "default": "'sfw'" 2068 }, 2069 "declared_age": { 2070 "name": "declared_age", 2071 "type": "integer", 2072 "primaryKey": false, 2073 "notNull": false 2074 }, 2075 "muted_words": { 2076 "name": "muted_words", 2077 "type": "jsonb", 2078 "primaryKey": false, 2079 "notNull": true, 2080 "default": "'[]'::jsonb" 2081 }, 2082 "blocked_dids": { 2083 "name": "blocked_dids", 2084 "type": "jsonb", 2085 "primaryKey": false, 2086 "notNull": true, 2087 "default": "'[]'::jsonb" 2088 }, 2089 "muted_dids": { 2090 "name": "muted_dids", 2091 "type": "jsonb", 2092 "primaryKey": false, 2093 "notNull": true, 2094 "default": "'[]'::jsonb" 2095 }, 2096 "cross_post_bluesky": { 2097 "name": "cross_post_bluesky", 2098 "type": "boolean", 2099 "primaryKey": false, 2100 "notNull": true, 2101 "default": false 2102 }, 2103 "cross_post_frontpage": { 2104 "name": "cross_post_frontpage", 2105 "type": "boolean", 2106 "primaryKey": false, 2107 "notNull": true, 2108 "default": false 2109 }, 2110 "cross_post_scopes_granted": { 2111 "name": "cross_post_scopes_granted", 2112 "type": "boolean", 2113 "primaryKey": false, 2114 "notNull": true, 2115 "default": false 2116 }, 2117 "updated_at": { 2118 "name": "updated_at", 2119 "type": "timestamp with time zone", 2120 "primaryKey": false, 2121 "notNull": true, 2122 "default": "now()" 2123 } 2124 }, 2125 "indexes": {}, 2126 "foreignKeys": {}, 2127 "compositePrimaryKeys": {}, 2128 "uniqueConstraints": {}, 2129 "policies": {}, 2130 "checkConstraints": {}, 2131 "isRLSEnabled": false 2132 }, 2133 "public.cross_posts": { 2134 "name": "cross_posts", 2135 "schema": "", 2136 "columns": { 2137 "id": { 2138 "name": "id", 2139 "type": "text", 2140 "primaryKey": true, 2141 "notNull": true 2142 }, 2143 "topic_uri": { 2144 "name": "topic_uri", 2145 "type": "text", 2146 "primaryKey": false, 2147 "notNull": true 2148 }, 2149 "service": { 2150 "name": "service", 2151 "type": "text", 2152 "primaryKey": false, 2153 "notNull": true 2154 }, 2155 "cross_post_uri": { 2156 "name": "cross_post_uri", 2157 "type": "text", 2158 "primaryKey": false, 2159 "notNull": true 2160 }, 2161 "cross_post_cid": { 2162 "name": "cross_post_cid", 2163 "type": "text", 2164 "primaryKey": false, 2165 "notNull": true 2166 }, 2167 "author_did": { 2168 "name": "author_did", 2169 "type": "text", 2170 "primaryKey": false, 2171 "notNull": true 2172 }, 2173 "created_at": { 2174 "name": "created_at", 2175 "type": "timestamp with time zone", 2176 "primaryKey": false, 2177 "notNull": true, 2178 "default": "now()" 2179 } 2180 }, 2181 "indexes": { 2182 "cross_posts_topic_uri_idx": { 2183 "name": "cross_posts_topic_uri_idx", 2184 "columns": [ 2185 { 2186 "expression": "topic_uri", 2187 "isExpression": false, 2188 "asc": true, 2189 "nulls": "last" 2190 } 2191 ], 2192 "isUnique": false, 2193 "concurrently": false, 2194 "method": "btree", 2195 "with": {} 2196 }, 2197 "cross_posts_author_did_idx": { 2198 "name": "cross_posts_author_did_idx", 2199 "columns": [ 2200 { 2201 "expression": "author_did", 2202 "isExpression": false, 2203 "asc": true, 2204 "nulls": "last" 2205 } 2206 ], 2207 "isUnique": false, 2208 "concurrently": false, 2209 "method": "btree", 2210 "with": {} 2211 } 2212 }, 2213 "foreignKeys": {}, 2214 "compositePrimaryKeys": {}, 2215 "uniqueConstraints": {}, 2216 "policies": {}, 2217 "checkConstraints": {}, 2218 "isRLSEnabled": false 2219 }, 2220 "public.community_onboarding_fields": { 2221 "name": "community_onboarding_fields", 2222 "schema": "", 2223 "columns": { 2224 "id": { 2225 "name": "id", 2226 "type": "text", 2227 "primaryKey": true, 2228 "notNull": true 2229 }, 2230 "community_did": { 2231 "name": "community_did", 2232 "type": "text", 2233 "primaryKey": false, 2234 "notNull": true 2235 }, 2236 "field_type": { 2237 "name": "field_type", 2238 "type": "text", 2239 "primaryKey": false, 2240 "notNull": true 2241 }, 2242 "label": { 2243 "name": "label", 2244 "type": "text", 2245 "primaryKey": false, 2246 "notNull": true 2247 }, 2248 "description": { 2249 "name": "description", 2250 "type": "text", 2251 "primaryKey": false, 2252 "notNull": false 2253 }, 2254 "is_mandatory": { 2255 "name": "is_mandatory", 2256 "type": "boolean", 2257 "primaryKey": false, 2258 "notNull": true, 2259 "default": true 2260 }, 2261 "sort_order": { 2262 "name": "sort_order", 2263 "type": "integer", 2264 "primaryKey": false, 2265 "notNull": true, 2266 "default": 0 2267 }, 2268 "config": { 2269 "name": "config", 2270 "type": "jsonb", 2271 "primaryKey": false, 2272 "notNull": false 2273 }, 2274 "created_at": { 2275 "name": "created_at", 2276 "type": "timestamp with time zone", 2277 "primaryKey": false, 2278 "notNull": true, 2279 "default": "now()" 2280 }, 2281 "updated_at": { 2282 "name": "updated_at", 2283 "type": "timestamp with time zone", 2284 "primaryKey": false, 2285 "notNull": true, 2286 "default": "now()" 2287 } 2288 }, 2289 "indexes": { 2290 "onboarding_fields_community_idx": { 2291 "name": "onboarding_fields_community_idx", 2292 "columns": [ 2293 { 2294 "expression": "community_did", 2295 "isExpression": false, 2296 "asc": true, 2297 "nulls": "last" 2298 } 2299 ], 2300 "isUnique": false, 2301 "concurrently": false, 2302 "method": "btree", 2303 "with": {} 2304 } 2305 }, 2306 "foreignKeys": {}, 2307 "compositePrimaryKeys": {}, 2308 "uniqueConstraints": {}, 2309 "policies": { 2310 "tenant_isolation": { 2311 "name": "tenant_isolation", 2312 "as": "PERMISSIVE", 2313 "for": "ALL", 2314 "to": ["barazo_app"], 2315 "using": "community_did = current_setting('app.current_community_did', true)", 2316 "withCheck": "community_did = current_setting('app.current_community_did', true)" 2317 } 2318 }, 2319 "checkConstraints": {}, 2320 "isRLSEnabled": true 2321 }, 2322 "public.user_onboarding_responses": { 2323 "name": "user_onboarding_responses", 2324 "schema": "", 2325 "columns": { 2326 "did": { 2327 "name": "did", 2328 "type": "text", 2329 "primaryKey": false, 2330 "notNull": true 2331 }, 2332 "community_did": { 2333 "name": "community_did", 2334 "type": "text", 2335 "primaryKey": false, 2336 "notNull": true 2337 }, 2338 "field_id": { 2339 "name": "field_id", 2340 "type": "text", 2341 "primaryKey": false, 2342 "notNull": true 2343 }, 2344 "response": { 2345 "name": "response", 2346 "type": "jsonb", 2347 "primaryKey": false, 2348 "notNull": true 2349 }, 2350 "completed_at": { 2351 "name": "completed_at", 2352 "type": "timestamp with time zone", 2353 "primaryKey": false, 2354 "notNull": true, 2355 "default": "now()" 2356 } 2357 }, 2358 "indexes": { 2359 "onboarding_responses_did_community_idx": { 2360 "name": "onboarding_responses_did_community_idx", 2361 "columns": [ 2362 { 2363 "expression": "did", 2364 "isExpression": false, 2365 "asc": true, 2366 "nulls": "last" 2367 }, 2368 { 2369 "expression": "community_did", 2370 "isExpression": false, 2371 "asc": true, 2372 "nulls": "last" 2373 } 2374 ], 2375 "isUnique": false, 2376 "concurrently": false, 2377 "method": "btree", 2378 "with": {} 2379 } 2380 }, 2381 "foreignKeys": {}, 2382 "compositePrimaryKeys": { 2383 "user_onboarding_responses_did_community_did_field_id_pk": { 2384 "name": "user_onboarding_responses_did_community_did_field_id_pk", 2385 "columns": ["did", "community_did", "field_id"] 2386 } 2387 }, 2388 "uniqueConstraints": {}, 2389 "policies": { 2390 "tenant_isolation": { 2391 "name": "tenant_isolation", 2392 "as": "PERMISSIVE", 2393 "for": "ALL", 2394 "to": ["barazo_app"], 2395 "using": "community_did = current_setting('app.current_community_did', true)", 2396 "withCheck": "community_did = current_setting('app.current_community_did', true)" 2397 } 2398 }, 2399 "checkConstraints": {}, 2400 "isRLSEnabled": true 2401 }, 2402 "public.moderation_queue": { 2403 "name": "moderation_queue", 2404 "schema": "", 2405 "columns": { 2406 "id": { 2407 "name": "id", 2408 "type": "serial", 2409 "primaryKey": true, 2410 "notNull": true 2411 }, 2412 "content_uri": { 2413 "name": "content_uri", 2414 "type": "text", 2415 "primaryKey": false, 2416 "notNull": true 2417 }, 2418 "content_type": { 2419 "name": "content_type", 2420 "type": "text", 2421 "primaryKey": false, 2422 "notNull": true 2423 }, 2424 "author_did": { 2425 "name": "author_did", 2426 "type": "text", 2427 "primaryKey": false, 2428 "notNull": true 2429 }, 2430 "community_did": { 2431 "name": "community_did", 2432 "type": "text", 2433 "primaryKey": false, 2434 "notNull": true 2435 }, 2436 "queue_reason": { 2437 "name": "queue_reason", 2438 "type": "text", 2439 "primaryKey": false, 2440 "notNull": true 2441 }, 2442 "matched_words": { 2443 "name": "matched_words", 2444 "type": "jsonb", 2445 "primaryKey": false, 2446 "notNull": false 2447 }, 2448 "status": { 2449 "name": "status", 2450 "type": "text", 2451 "primaryKey": false, 2452 "notNull": true, 2453 "default": "'pending'" 2454 }, 2455 "reviewed_by": { 2456 "name": "reviewed_by", 2457 "type": "text", 2458 "primaryKey": false, 2459 "notNull": false 2460 }, 2461 "created_at": { 2462 "name": "created_at", 2463 "type": "timestamp with time zone", 2464 "primaryKey": false, 2465 "notNull": true, 2466 "default": "now()" 2467 }, 2468 "reviewed_at": { 2469 "name": "reviewed_at", 2470 "type": "timestamp with time zone", 2471 "primaryKey": false, 2472 "notNull": false 2473 } 2474 }, 2475 "indexes": { 2476 "mod_queue_author_did_idx": { 2477 "name": "mod_queue_author_did_idx", 2478 "columns": [ 2479 { 2480 "expression": "author_did", 2481 "isExpression": false, 2482 "asc": true, 2483 "nulls": "last" 2484 } 2485 ], 2486 "isUnique": false, 2487 "concurrently": false, 2488 "method": "btree", 2489 "with": {} 2490 }, 2491 "mod_queue_community_did_idx": { 2492 "name": "mod_queue_community_did_idx", 2493 "columns": [ 2494 { 2495 "expression": "community_did", 2496 "isExpression": false, 2497 "asc": true, 2498 "nulls": "last" 2499 } 2500 ], 2501 "isUnique": false, 2502 "concurrently": false, 2503 "method": "btree", 2504 "with": {} 2505 }, 2506 "mod_queue_status_idx": { 2507 "name": "mod_queue_status_idx", 2508 "columns": [ 2509 { 2510 "expression": "status", 2511 "isExpression": false, 2512 "asc": true, 2513 "nulls": "last" 2514 } 2515 ], 2516 "isUnique": false, 2517 "concurrently": false, 2518 "method": "btree", 2519 "with": {} 2520 }, 2521 "mod_queue_created_at_idx": { 2522 "name": "mod_queue_created_at_idx", 2523 "columns": [ 2524 { 2525 "expression": "created_at", 2526 "isExpression": false, 2527 "asc": true, 2528 "nulls": "last" 2529 } 2530 ], 2531 "isUnique": false, 2532 "concurrently": false, 2533 "method": "btree", 2534 "with": {} 2535 }, 2536 "mod_queue_content_uri_idx": { 2537 "name": "mod_queue_content_uri_idx", 2538 "columns": [ 2539 { 2540 "expression": "content_uri", 2541 "isExpression": false, 2542 "asc": true, 2543 "nulls": "last" 2544 } 2545 ], 2546 "isUnique": false, 2547 "concurrently": false, 2548 "method": "btree", 2549 "with": {} 2550 } 2551 }, 2552 "foreignKeys": {}, 2553 "compositePrimaryKeys": {}, 2554 "uniqueConstraints": {}, 2555 "policies": { 2556 "tenant_isolation": { 2557 "name": "tenant_isolation", 2558 "as": "PERMISSIVE", 2559 "for": "ALL", 2560 "to": ["barazo_app"], 2561 "using": "community_did = current_setting('app.current_community_did', true)", 2562 "withCheck": "community_did = current_setting('app.current_community_did', true)" 2563 } 2564 }, 2565 "checkConstraints": {}, 2566 "isRLSEnabled": true 2567 }, 2568 "public.account_trust": { 2569 "name": "account_trust", 2570 "schema": "", 2571 "columns": { 2572 "id": { 2573 "name": "id", 2574 "type": "serial", 2575 "primaryKey": true, 2576 "notNull": true 2577 }, 2578 "did": { 2579 "name": "did", 2580 "type": "text", 2581 "primaryKey": false, 2582 "notNull": true 2583 }, 2584 "community_did": { 2585 "name": "community_did", 2586 "type": "text", 2587 "primaryKey": false, 2588 "notNull": true 2589 }, 2590 "approved_post_count": { 2591 "name": "approved_post_count", 2592 "type": "integer", 2593 "primaryKey": false, 2594 "notNull": true, 2595 "default": 0 2596 }, 2597 "is_trusted": { 2598 "name": "is_trusted", 2599 "type": "boolean", 2600 "primaryKey": false, 2601 "notNull": true, 2602 "default": false 2603 }, 2604 "trusted_at": { 2605 "name": "trusted_at", 2606 "type": "timestamp with time zone", 2607 "primaryKey": false, 2608 "notNull": false 2609 } 2610 }, 2611 "indexes": { 2612 "account_trust_did_community_idx": { 2613 "name": "account_trust_did_community_idx", 2614 "columns": [ 2615 { 2616 "expression": "did", 2617 "isExpression": false, 2618 "asc": true, 2619 "nulls": "last" 2620 }, 2621 { 2622 "expression": "community_did", 2623 "isExpression": false, 2624 "asc": true, 2625 "nulls": "last" 2626 } 2627 ], 2628 "isUnique": true, 2629 "concurrently": false, 2630 "method": "btree", 2631 "with": {} 2632 }, 2633 "account_trust_did_idx": { 2634 "name": "account_trust_did_idx", 2635 "columns": [ 2636 { 2637 "expression": "did", 2638 "isExpression": false, 2639 "asc": true, 2640 "nulls": "last" 2641 } 2642 ], 2643 "isUnique": false, 2644 "concurrently": false, 2645 "method": "btree", 2646 "with": {} 2647 } 2648 }, 2649 "foreignKeys": {}, 2650 "compositePrimaryKeys": {}, 2651 "uniqueConstraints": {}, 2652 "policies": { 2653 "tenant_isolation": { 2654 "name": "tenant_isolation", 2655 "as": "PERMISSIVE", 2656 "for": "ALL", 2657 "to": ["barazo_app"], 2658 "using": "community_did = current_setting('app.current_community_did', true)", 2659 "withCheck": "community_did = current_setting('app.current_community_did', true)" 2660 } 2661 }, 2662 "checkConstraints": {}, 2663 "isRLSEnabled": true 2664 }, 2665 "public.community_filters": { 2666 "name": "community_filters", 2667 "schema": "", 2668 "columns": { 2669 "community_did": { 2670 "name": "community_did", 2671 "type": "text", 2672 "primaryKey": true, 2673 "notNull": true 2674 }, 2675 "status": { 2676 "name": "status", 2677 "type": "text", 2678 "primaryKey": false, 2679 "notNull": true, 2680 "default": "'active'" 2681 }, 2682 "admin_did": { 2683 "name": "admin_did", 2684 "type": "text", 2685 "primaryKey": false, 2686 "notNull": false 2687 }, 2688 "reason": { 2689 "name": "reason", 2690 "type": "text", 2691 "primaryKey": false, 2692 "notNull": false 2693 }, 2694 "report_count": { 2695 "name": "report_count", 2696 "type": "integer", 2697 "primaryKey": false, 2698 "notNull": true, 2699 "default": 0 2700 }, 2701 "last_reviewed_at": { 2702 "name": "last_reviewed_at", 2703 "type": "timestamp with time zone", 2704 "primaryKey": false, 2705 "notNull": false 2706 }, 2707 "filtered_by": { 2708 "name": "filtered_by", 2709 "type": "text", 2710 "primaryKey": false, 2711 "notNull": false 2712 }, 2713 "created_at": { 2714 "name": "created_at", 2715 "type": "timestamp with time zone", 2716 "primaryKey": false, 2717 "notNull": true, 2718 "default": "now()" 2719 }, 2720 "updated_at": { 2721 "name": "updated_at", 2722 "type": "timestamp with time zone", 2723 "primaryKey": false, 2724 "notNull": true, 2725 "default": "now()" 2726 } 2727 }, 2728 "indexes": { 2729 "community_filters_status_idx": { 2730 "name": "community_filters_status_idx", 2731 "columns": [ 2732 { 2733 "expression": "status", 2734 "isExpression": false, 2735 "asc": true, 2736 "nulls": "last" 2737 } 2738 ], 2739 "isUnique": false, 2740 "concurrently": false, 2741 "method": "btree", 2742 "with": {} 2743 }, 2744 "community_filters_admin_did_idx": { 2745 "name": "community_filters_admin_did_idx", 2746 "columns": [ 2747 { 2748 "expression": "admin_did", 2749 "isExpression": false, 2750 "asc": true, 2751 "nulls": "last" 2752 } 2753 ], 2754 "isUnique": false, 2755 "concurrently": false, 2756 "method": "btree", 2757 "with": {} 2758 }, 2759 "community_filters_updated_at_idx": { 2760 "name": "community_filters_updated_at_idx", 2761 "columns": [ 2762 { 2763 "expression": "updated_at", 2764 "isExpression": false, 2765 "asc": true, 2766 "nulls": "last" 2767 } 2768 ], 2769 "isUnique": false, 2770 "concurrently": false, 2771 "method": "btree", 2772 "with": {} 2773 } 2774 }, 2775 "foreignKeys": {}, 2776 "compositePrimaryKeys": {}, 2777 "uniqueConstraints": {}, 2778 "policies": { 2779 "tenant_isolation": { 2780 "name": "tenant_isolation", 2781 "as": "PERMISSIVE", 2782 "for": "ALL", 2783 "to": ["barazo_app"], 2784 "using": "community_did = current_setting('app.current_community_did', true)", 2785 "withCheck": "community_did = current_setting('app.current_community_did', true)" 2786 } 2787 }, 2788 "checkConstraints": {}, 2789 "isRLSEnabled": true 2790 }, 2791 "public.account_filters": { 2792 "name": "account_filters", 2793 "schema": "", 2794 "columns": { 2795 "id": { 2796 "name": "id", 2797 "type": "serial", 2798 "primaryKey": true, 2799 "notNull": true 2800 }, 2801 "did": { 2802 "name": "did", 2803 "type": "text", 2804 "primaryKey": false, 2805 "notNull": true 2806 }, 2807 "community_did": { 2808 "name": "community_did", 2809 "type": "text", 2810 "primaryKey": false, 2811 "notNull": true 2812 }, 2813 "status": { 2814 "name": "status", 2815 "type": "text", 2816 "primaryKey": false, 2817 "notNull": true, 2818 "default": "'active'" 2819 }, 2820 "reason": { 2821 "name": "reason", 2822 "type": "text", 2823 "primaryKey": false, 2824 "notNull": false 2825 }, 2826 "report_count": { 2827 "name": "report_count", 2828 "type": "integer", 2829 "primaryKey": false, 2830 "notNull": true, 2831 "default": 0 2832 }, 2833 "ban_count": { 2834 "name": "ban_count", 2835 "type": "integer", 2836 "primaryKey": false, 2837 "notNull": true, 2838 "default": 0 2839 }, 2840 "last_reviewed_at": { 2841 "name": "last_reviewed_at", 2842 "type": "timestamp with time zone", 2843 "primaryKey": false, 2844 "notNull": false 2845 }, 2846 "filtered_by": { 2847 "name": "filtered_by", 2848 "type": "text", 2849 "primaryKey": false, 2850 "notNull": false 2851 }, 2852 "created_at": { 2853 "name": "created_at", 2854 "type": "timestamp with time zone", 2855 "primaryKey": false, 2856 "notNull": true, 2857 "default": "now()" 2858 }, 2859 "updated_at": { 2860 "name": "updated_at", 2861 "type": "timestamp with time zone", 2862 "primaryKey": false, 2863 "notNull": true, 2864 "default": "now()" 2865 } 2866 }, 2867 "indexes": { 2868 "account_filters_did_community_idx": { 2869 "name": "account_filters_did_community_idx", 2870 "columns": [ 2871 { 2872 "expression": "did", 2873 "isExpression": false, 2874 "asc": true, 2875 "nulls": "last" 2876 }, 2877 { 2878 "expression": "community_did", 2879 "isExpression": false, 2880 "asc": true, 2881 "nulls": "last" 2882 } 2883 ], 2884 "isUnique": true, 2885 "concurrently": false, 2886 "method": "btree", 2887 "with": {} 2888 }, 2889 "account_filters_did_idx": { 2890 "name": "account_filters_did_idx", 2891 "columns": [ 2892 { 2893 "expression": "did", 2894 "isExpression": false, 2895 "asc": true, 2896 "nulls": "last" 2897 } 2898 ], 2899 "isUnique": false, 2900 "concurrently": false, 2901 "method": "btree", 2902 "with": {} 2903 }, 2904 "account_filters_community_did_idx": { 2905 "name": "account_filters_community_did_idx", 2906 "columns": [ 2907 { 2908 "expression": "community_did", 2909 "isExpression": false, 2910 "asc": true, 2911 "nulls": "last" 2912 } 2913 ], 2914 "isUnique": false, 2915 "concurrently": false, 2916 "method": "btree", 2917 "with": {} 2918 }, 2919 "account_filters_status_idx": { 2920 "name": "account_filters_status_idx", 2921 "columns": [ 2922 { 2923 "expression": "status", 2924 "isExpression": false, 2925 "asc": true, 2926 "nulls": "last" 2927 } 2928 ], 2929 "isUnique": false, 2930 "concurrently": false, 2931 "method": "btree", 2932 "with": {} 2933 }, 2934 "account_filters_updated_at_idx": { 2935 "name": "account_filters_updated_at_idx", 2936 "columns": [ 2937 { 2938 "expression": "updated_at", 2939 "isExpression": false, 2940 "asc": true, 2941 "nulls": "last" 2942 } 2943 ], 2944 "isUnique": false, 2945 "concurrently": false, 2946 "method": "btree", 2947 "with": {} 2948 } 2949 }, 2950 "foreignKeys": {}, 2951 "compositePrimaryKeys": {}, 2952 "uniqueConstraints": {}, 2953 "policies": { 2954 "tenant_isolation": { 2955 "name": "tenant_isolation", 2956 "as": "PERMISSIVE", 2957 "for": "ALL", 2958 "to": ["barazo_app"], 2959 "using": "community_did = current_setting('app.current_community_did', true)", 2960 "withCheck": "community_did = current_setting('app.current_community_did', true)" 2961 } 2962 }, 2963 "checkConstraints": {}, 2964 "isRLSEnabled": true 2965 }, 2966 "public.ozone_labels": { 2967 "name": "ozone_labels", 2968 "schema": "", 2969 "columns": { 2970 "id": { 2971 "name": "id", 2972 "type": "serial", 2973 "primaryKey": true, 2974 "notNull": true 2975 }, 2976 "src": { 2977 "name": "src", 2978 "type": "text", 2979 "primaryKey": false, 2980 "notNull": true 2981 }, 2982 "uri": { 2983 "name": "uri", 2984 "type": "text", 2985 "primaryKey": false, 2986 "notNull": true 2987 }, 2988 "val": { 2989 "name": "val", 2990 "type": "text", 2991 "primaryKey": false, 2992 "notNull": true 2993 }, 2994 "neg": { 2995 "name": "neg", 2996 "type": "boolean", 2997 "primaryKey": false, 2998 "notNull": true, 2999 "default": false 3000 }, 3001 "cts": { 3002 "name": "cts", 3003 "type": "timestamp with time zone", 3004 "primaryKey": false, 3005 "notNull": true 3006 }, 3007 "exp": { 3008 "name": "exp", 3009 "type": "timestamp with time zone", 3010 "primaryKey": false, 3011 "notNull": false 3012 }, 3013 "indexed_at": { 3014 "name": "indexed_at", 3015 "type": "timestamp with time zone", 3016 "primaryKey": false, 3017 "notNull": true, 3018 "default": "now()" 3019 } 3020 }, 3021 "indexes": { 3022 "ozone_labels_src_uri_val_idx": { 3023 "name": "ozone_labels_src_uri_val_idx", 3024 "columns": [ 3025 { 3026 "expression": "src", 3027 "isExpression": false, 3028 "asc": true, 3029 "nulls": "last" 3030 }, 3031 { 3032 "expression": "uri", 3033 "isExpression": false, 3034 "asc": true, 3035 "nulls": "last" 3036 }, 3037 { 3038 "expression": "val", 3039 "isExpression": false, 3040 "asc": true, 3041 "nulls": "last" 3042 } 3043 ], 3044 "isUnique": true, 3045 "concurrently": false, 3046 "method": "btree", 3047 "with": {} 3048 }, 3049 "ozone_labels_uri_idx": { 3050 "name": "ozone_labels_uri_idx", 3051 "columns": [ 3052 { 3053 "expression": "uri", 3054 "isExpression": false, 3055 "asc": true, 3056 "nulls": "last" 3057 } 3058 ], 3059 "isUnique": false, 3060 "concurrently": false, 3061 "method": "btree", 3062 "with": {} 3063 }, 3064 "ozone_labels_val_idx": { 3065 "name": "ozone_labels_val_idx", 3066 "columns": [ 3067 { 3068 "expression": "val", 3069 "isExpression": false, 3070 "asc": true, 3071 "nulls": "last" 3072 } 3073 ], 3074 "isUnique": false, 3075 "concurrently": false, 3076 "method": "btree", 3077 "with": {} 3078 }, 3079 "ozone_labels_indexed_at_idx": { 3080 "name": "ozone_labels_indexed_at_idx", 3081 "columns": [ 3082 { 3083 "expression": "indexed_at", 3084 "isExpression": false, 3085 "asc": true, 3086 "nulls": "last" 3087 } 3088 ], 3089 "isUnique": false, 3090 "concurrently": false, 3091 "method": "btree", 3092 "with": {} 3093 } 3094 }, 3095 "foreignKeys": {}, 3096 "compositePrimaryKeys": {}, 3097 "uniqueConstraints": {}, 3098 "policies": {}, 3099 "checkConstraints": {}, 3100 "isRLSEnabled": false 3101 }, 3102 "public.community_profiles": { 3103 "name": "community_profiles", 3104 "schema": "", 3105 "columns": { 3106 "did": { 3107 "name": "did", 3108 "type": "text", 3109 "primaryKey": false, 3110 "notNull": true 3111 }, 3112 "community_did": { 3113 "name": "community_did", 3114 "type": "text", 3115 "primaryKey": false, 3116 "notNull": true 3117 }, 3118 "display_name": { 3119 "name": "display_name", 3120 "type": "text", 3121 "primaryKey": false, 3122 "notNull": false 3123 }, 3124 "avatar_url": { 3125 "name": "avatar_url", 3126 "type": "text", 3127 "primaryKey": false, 3128 "notNull": false 3129 }, 3130 "banner_url": { 3131 "name": "banner_url", 3132 "type": "text", 3133 "primaryKey": false, 3134 "notNull": false 3135 }, 3136 "bio": { 3137 "name": "bio", 3138 "type": "text", 3139 "primaryKey": false, 3140 "notNull": false 3141 }, 3142 "updated_at": { 3143 "name": "updated_at", 3144 "type": "timestamp with time zone", 3145 "primaryKey": false, 3146 "notNull": true, 3147 "default": "now()" 3148 } 3149 }, 3150 "indexes": { 3151 "community_profiles_did_idx": { 3152 "name": "community_profiles_did_idx", 3153 "columns": [ 3154 { 3155 "expression": "did", 3156 "isExpression": false, 3157 "asc": true, 3158 "nulls": "last" 3159 } 3160 ], 3161 "isUnique": false, 3162 "concurrently": false, 3163 "method": "btree", 3164 "with": {} 3165 }, 3166 "community_profiles_community_idx": { 3167 "name": "community_profiles_community_idx", 3168 "columns": [ 3169 { 3170 "expression": "community_did", 3171 "isExpression": false, 3172 "asc": true, 3173 "nulls": "last" 3174 } 3175 ], 3176 "isUnique": false, 3177 "concurrently": false, 3178 "method": "btree", 3179 "with": {} 3180 } 3181 }, 3182 "foreignKeys": {}, 3183 "compositePrimaryKeys": { 3184 "community_profiles_did_community_did_pk": { 3185 "name": "community_profiles_did_community_did_pk", 3186 "columns": ["did", "community_did"] 3187 } 3188 }, 3189 "uniqueConstraints": {}, 3190 "policies": { 3191 "tenant_isolation": { 3192 "name": "tenant_isolation", 3193 "as": "PERMISSIVE", 3194 "for": "ALL", 3195 "to": ["barazo_app"], 3196 "using": "community_did = current_setting('app.current_community_did', true)", 3197 "withCheck": "community_did = current_setting('app.current_community_did', true)" 3198 } 3199 }, 3200 "checkConstraints": {}, 3201 "isRLSEnabled": true 3202 }, 3203 "public.interaction_graph": { 3204 "name": "interaction_graph", 3205 "schema": "", 3206 "columns": { 3207 "source_did": { 3208 "name": "source_did", 3209 "type": "text", 3210 "primaryKey": false, 3211 "notNull": true 3212 }, 3213 "target_did": { 3214 "name": "target_did", 3215 "type": "text", 3216 "primaryKey": false, 3217 "notNull": true 3218 }, 3219 "community_id": { 3220 "name": "community_id", 3221 "type": "text", 3222 "primaryKey": false, 3223 "notNull": true 3224 }, 3225 "interaction_type": { 3226 "name": "interaction_type", 3227 "type": "text", 3228 "primaryKey": false, 3229 "notNull": true 3230 }, 3231 "weight": { 3232 "name": "weight", 3233 "type": "integer", 3234 "primaryKey": false, 3235 "notNull": true, 3236 "default": 1 3237 }, 3238 "first_interaction_at": { 3239 "name": "first_interaction_at", 3240 "type": "timestamp with time zone", 3241 "primaryKey": false, 3242 "notNull": true, 3243 "default": "now()" 3244 }, 3245 "last_interaction_at": { 3246 "name": "last_interaction_at", 3247 "type": "timestamp with time zone", 3248 "primaryKey": false, 3249 "notNull": true, 3250 "default": "now()" 3251 } 3252 }, 3253 "indexes": { 3254 "interaction_graph_source_target_community_idx": { 3255 "name": "interaction_graph_source_target_community_idx", 3256 "columns": [ 3257 { 3258 "expression": "source_did", 3259 "isExpression": false, 3260 "asc": true, 3261 "nulls": "last" 3262 }, 3263 { 3264 "expression": "target_did", 3265 "isExpression": false, 3266 "asc": true, 3267 "nulls": "last" 3268 }, 3269 { 3270 "expression": "community_id", 3271 "isExpression": false, 3272 "asc": true, 3273 "nulls": "last" 3274 } 3275 ], 3276 "isUnique": false, 3277 "concurrently": false, 3278 "method": "btree", 3279 "with": {} 3280 } 3281 }, 3282 "foreignKeys": {}, 3283 "compositePrimaryKeys": { 3284 "interaction_graph_source_did_target_did_community_id_interaction_type_pk": { 3285 "name": "interaction_graph_source_did_target_did_community_id_interaction_type_pk", 3286 "columns": ["source_did", "target_did", "community_id", "interaction_type"] 3287 } 3288 }, 3289 "uniqueConstraints": {}, 3290 "policies": {}, 3291 "checkConstraints": {}, 3292 "isRLSEnabled": false 3293 }, 3294 "public.trust_seeds": { 3295 "name": "trust_seeds", 3296 "schema": "", 3297 "columns": { 3298 "id": { 3299 "name": "id", 3300 "type": "serial", 3301 "primaryKey": true, 3302 "notNull": true 3303 }, 3304 "did": { 3305 "name": "did", 3306 "type": "text", 3307 "primaryKey": false, 3308 "notNull": true 3309 }, 3310 "community_id": { 3311 "name": "community_id", 3312 "type": "text", 3313 "primaryKey": false, 3314 "notNull": true, 3315 "default": "''" 3316 }, 3317 "added_by": { 3318 "name": "added_by", 3319 "type": "text", 3320 "primaryKey": false, 3321 "notNull": true 3322 }, 3323 "reason": { 3324 "name": "reason", 3325 "type": "text", 3326 "primaryKey": false, 3327 "notNull": false 3328 }, 3329 "created_at": { 3330 "name": "created_at", 3331 "type": "timestamp with time zone", 3332 "primaryKey": false, 3333 "notNull": true, 3334 "default": "now()" 3335 } 3336 }, 3337 "indexes": { 3338 "trust_seeds_did_community_idx": { 3339 "name": "trust_seeds_did_community_idx", 3340 "columns": [ 3341 { 3342 "expression": "did", 3343 "isExpression": false, 3344 "asc": true, 3345 "nulls": "last" 3346 }, 3347 { 3348 "expression": "community_id", 3349 "isExpression": false, 3350 "asc": true, 3351 "nulls": "last" 3352 } 3353 ], 3354 "isUnique": true, 3355 "concurrently": false, 3356 "method": "btree", 3357 "with": {} 3358 } 3359 }, 3360 "foreignKeys": {}, 3361 "compositePrimaryKeys": {}, 3362 "uniqueConstraints": {}, 3363 "policies": {}, 3364 "checkConstraints": {}, 3365 "isRLSEnabled": false 3366 }, 3367 "public.trust_scores": { 3368 "name": "trust_scores", 3369 "schema": "", 3370 "columns": { 3371 "did": { 3372 "name": "did", 3373 "type": "text", 3374 "primaryKey": false, 3375 "notNull": true 3376 }, 3377 "community_id": { 3378 "name": "community_id", 3379 "type": "text", 3380 "primaryKey": false, 3381 "notNull": true, 3382 "default": "''" 3383 }, 3384 "score": { 3385 "name": "score", 3386 "type": "real", 3387 "primaryKey": false, 3388 "notNull": true 3389 }, 3390 "computed_at": { 3391 "name": "computed_at", 3392 "type": "timestamp with time zone", 3393 "primaryKey": false, 3394 "notNull": true, 3395 "default": "now()" 3396 } 3397 }, 3398 "indexes": { 3399 "trust_scores_did_community_idx": { 3400 "name": "trust_scores_did_community_idx", 3401 "columns": [ 3402 { 3403 "expression": "did", 3404 "isExpression": false, 3405 "asc": true, 3406 "nulls": "last" 3407 }, 3408 { 3409 "expression": "community_id", 3410 "isExpression": false, 3411 "asc": true, 3412 "nulls": "last" 3413 } 3414 ], 3415 "isUnique": false, 3416 "concurrently": false, 3417 "method": "btree", 3418 "with": {} 3419 } 3420 }, 3421 "foreignKeys": {}, 3422 "compositePrimaryKeys": { 3423 "trust_scores_did_community_id_pk": { 3424 "name": "trust_scores_did_community_id_pk", 3425 "columns": ["did", "community_id"] 3426 } 3427 }, 3428 "uniqueConstraints": {}, 3429 "policies": {}, 3430 "checkConstraints": {}, 3431 "isRLSEnabled": false 3432 }, 3433 "public.sybil_clusters": { 3434 "name": "sybil_clusters", 3435 "schema": "", 3436 "columns": { 3437 "id": { 3438 "name": "id", 3439 "type": "serial", 3440 "primaryKey": true, 3441 "notNull": true 3442 }, 3443 "cluster_hash": { 3444 "name": "cluster_hash", 3445 "type": "text", 3446 "primaryKey": false, 3447 "notNull": true 3448 }, 3449 "internal_edge_count": { 3450 "name": "internal_edge_count", 3451 "type": "integer", 3452 "primaryKey": false, 3453 "notNull": true 3454 }, 3455 "external_edge_count": { 3456 "name": "external_edge_count", 3457 "type": "integer", 3458 "primaryKey": false, 3459 "notNull": true 3460 }, 3461 "member_count": { 3462 "name": "member_count", 3463 "type": "integer", 3464 "primaryKey": false, 3465 "notNull": true 3466 }, 3467 "status": { 3468 "name": "status", 3469 "type": "text", 3470 "primaryKey": false, 3471 "notNull": true, 3472 "default": "'flagged'" 3473 }, 3474 "reviewed_by": { 3475 "name": "reviewed_by", 3476 "type": "text", 3477 "primaryKey": false, 3478 "notNull": false 3479 }, 3480 "reviewed_at": { 3481 "name": "reviewed_at", 3482 "type": "timestamp with time zone", 3483 "primaryKey": false, 3484 "notNull": false 3485 }, 3486 "detected_at": { 3487 "name": "detected_at", 3488 "type": "timestamp with time zone", 3489 "primaryKey": false, 3490 "notNull": true, 3491 "default": "now()" 3492 }, 3493 "updated_at": { 3494 "name": "updated_at", 3495 "type": "timestamp with time zone", 3496 "primaryKey": false, 3497 "notNull": true, 3498 "default": "now()" 3499 } 3500 }, 3501 "indexes": { 3502 "sybil_clusters_hash_idx": { 3503 "name": "sybil_clusters_hash_idx", 3504 "columns": [ 3505 { 3506 "expression": "cluster_hash", 3507 "isExpression": false, 3508 "asc": true, 3509 "nulls": "last" 3510 } 3511 ], 3512 "isUnique": true, 3513 "concurrently": false, 3514 "method": "btree", 3515 "with": {} 3516 } 3517 }, 3518 "foreignKeys": {}, 3519 "compositePrimaryKeys": {}, 3520 "uniqueConstraints": {}, 3521 "policies": {}, 3522 "checkConstraints": {}, 3523 "isRLSEnabled": false 3524 }, 3525 "public.sybil_cluster_members": { 3526 "name": "sybil_cluster_members", 3527 "schema": "", 3528 "columns": { 3529 "cluster_id": { 3530 "name": "cluster_id", 3531 "type": "integer", 3532 "primaryKey": false, 3533 "notNull": true 3534 }, 3535 "did": { 3536 "name": "did", 3537 "type": "text", 3538 "primaryKey": false, 3539 "notNull": true 3540 }, 3541 "role_in_cluster": { 3542 "name": "role_in_cluster", 3543 "type": "text", 3544 "primaryKey": false, 3545 "notNull": true 3546 }, 3547 "joined_at": { 3548 "name": "joined_at", 3549 "type": "timestamp with time zone", 3550 "primaryKey": false, 3551 "notNull": true, 3552 "default": "now()" 3553 } 3554 }, 3555 "indexes": {}, 3556 "foreignKeys": { 3557 "sybil_cluster_members_cluster_id_sybil_clusters_id_fk": { 3558 "name": "sybil_cluster_members_cluster_id_sybil_clusters_id_fk", 3559 "tableFrom": "sybil_cluster_members", 3560 "tableTo": "sybil_clusters", 3561 "columnsFrom": ["cluster_id"], 3562 "columnsTo": ["id"], 3563 "onDelete": "no action", 3564 "onUpdate": "no action" 3565 } 3566 }, 3567 "compositePrimaryKeys": { 3568 "sybil_cluster_members_cluster_id_did_pk": { 3569 "name": "sybil_cluster_members_cluster_id_did_pk", 3570 "columns": ["cluster_id", "did"] 3571 } 3572 }, 3573 "uniqueConstraints": {}, 3574 "policies": {}, 3575 "checkConstraints": {}, 3576 "isRLSEnabled": false 3577 }, 3578 "public.behavioral_flags": { 3579 "name": "behavioral_flags", 3580 "schema": "", 3581 "columns": { 3582 "id": { 3583 "name": "id", 3584 "type": "serial", 3585 "primaryKey": true, 3586 "notNull": true 3587 }, 3588 "flag_type": { 3589 "name": "flag_type", 3590 "type": "text", 3591 "primaryKey": false, 3592 "notNull": true 3593 }, 3594 "affected_dids": { 3595 "name": "affected_dids", 3596 "type": "jsonb", 3597 "primaryKey": false, 3598 "notNull": true 3599 }, 3600 "details": { 3601 "name": "details", 3602 "type": "text", 3603 "primaryKey": false, 3604 "notNull": true 3605 }, 3606 "community_did": { 3607 "name": "community_did", 3608 "type": "text", 3609 "primaryKey": false, 3610 "notNull": false 3611 }, 3612 "status": { 3613 "name": "status", 3614 "type": "text", 3615 "primaryKey": false, 3616 "notNull": true, 3617 "default": "'pending'" 3618 }, 3619 "detected_at": { 3620 "name": "detected_at", 3621 "type": "timestamp with time zone", 3622 "primaryKey": false, 3623 "notNull": true, 3624 "default": "now()" 3625 } 3626 }, 3627 "indexes": { 3628 "behavioral_flags_flag_type_idx": { 3629 "name": "behavioral_flags_flag_type_idx", 3630 "columns": [ 3631 { 3632 "expression": "flag_type", 3633 "isExpression": false, 3634 "asc": true, 3635 "nulls": "last" 3636 } 3637 ], 3638 "isUnique": false, 3639 "concurrently": false, 3640 "method": "btree", 3641 "with": {} 3642 }, 3643 "behavioral_flags_status_idx": { 3644 "name": "behavioral_flags_status_idx", 3645 "columns": [ 3646 { 3647 "expression": "status", 3648 "isExpression": false, 3649 "asc": true, 3650 "nulls": "last" 3651 } 3652 ], 3653 "isUnique": false, 3654 "concurrently": false, 3655 "method": "btree", 3656 "with": {} 3657 }, 3658 "behavioral_flags_detected_at_idx": { 3659 "name": "behavioral_flags_detected_at_idx", 3660 "columns": [ 3661 { 3662 "expression": "detected_at", 3663 "isExpression": false, 3664 "asc": true, 3665 "nulls": "last" 3666 } 3667 ], 3668 "isUnique": false, 3669 "concurrently": false, 3670 "method": "btree", 3671 "with": {} 3672 } 3673 }, 3674 "foreignKeys": {}, 3675 "compositePrimaryKeys": {}, 3676 "uniqueConstraints": {}, 3677 "policies": {}, 3678 "checkConstraints": {}, 3679 "isRLSEnabled": false 3680 }, 3681 "public.pds_trust_factors": { 3682 "name": "pds_trust_factors", 3683 "schema": "", 3684 "columns": { 3685 "id": { 3686 "name": "id", 3687 "type": "serial", 3688 "primaryKey": true, 3689 "notNull": true 3690 }, 3691 "pds_host": { 3692 "name": "pds_host", 3693 "type": "text", 3694 "primaryKey": false, 3695 "notNull": true 3696 }, 3697 "trust_factor": { 3698 "name": "trust_factor", 3699 "type": "real", 3700 "primaryKey": false, 3701 "notNull": true 3702 }, 3703 "is_default": { 3704 "name": "is_default", 3705 "type": "boolean", 3706 "primaryKey": false, 3707 "notNull": true, 3708 "default": false 3709 }, 3710 "updated_at": { 3711 "name": "updated_at", 3712 "type": "timestamp with time zone", 3713 "primaryKey": false, 3714 "notNull": true, 3715 "default": "now()" 3716 } 3717 }, 3718 "indexes": { 3719 "pds_trust_factors_pds_host_idx": { 3720 "name": "pds_trust_factors_pds_host_idx", 3721 "columns": [ 3722 { 3723 "expression": "pds_host", 3724 "isExpression": false, 3725 "asc": true, 3726 "nulls": "last" 3727 } 3728 ], 3729 "isUnique": true, 3730 "concurrently": false, 3731 "method": "btree", 3732 "with": {} 3733 } 3734 }, 3735 "foreignKeys": {}, 3736 "compositePrimaryKeys": {}, 3737 "uniqueConstraints": {}, 3738 "policies": {}, 3739 "checkConstraints": {}, 3740 "isRLSEnabled": false 3741 } 3742 }, 3743 "enums": {}, 3744 "schemas": {}, 3745 "sequences": {}, 3746 "roles": { 3747 "barazo_app": { 3748 "name": "barazo_app", 3749 "createDb": false, 3750 "createRole": false, 3751 "inherit": true 3752 } 3753 }, 3754 "policies": {}, 3755 "views": {}, 3756 "_meta": { 3757 "columns": {}, 3758 "schemas": {}, 3759 "tables": {} 3760 } 3761}