pyfocalboard
FocalboardApi
FocalboardApi(token: str | None, server: str, is_standalone=False, non_standard_api_url: str | None = None)
Source code in pyfocalboard/api.py
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 |
|
MM_PLUGIN_API_URL
MM_PLUGIN_API_URL = '/plugins/focalboard/api/v2'
STANDALONE_API_URL
STANDALONE_API_URL = '/api/v2'
api_url
api_url = api_url if not non_standard_api_url else non_standard_api_url
add_member
add_member(board_id: str, user_id: str, member: MemberBody | None = None) -> Member
Adds a new member to a board
Source code in pyfocalboard/api.py
374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 |
|
archive_board_export
archive_board_export(board_id: str) -> bytes
Exports an archive of all blocks for one boards.
Source code in pyfocalboard/api.py
419 420 421 422 423 424 425 426 427 428 429 |
|
archive_export_team
archive_export_team(team_id: str) -> bytes
Exports an archive of all blocks for one boards.
Source code in pyfocalboard/api.py
657 658 659 660 661 662 663 664 665 666 667 |
|
archive_import
archive_import(team_id: str, file: bytes) -> None
Import an archive of boards.
Source code in pyfocalboard/api.py
669 670 671 672 673 674 675 676 677 678 679 |
|
client_config
client_config() -> ClientConfig
Returns the client configuration
Source code in pyfocalboard/api.py
954 955 956 957 958 959 960 961 962 963 |
|
create_board
Creates a new board
Source code in pyfocalboard/api.py
260 261 262 263 264 265 266 267 268 269 270 271 272 |
|
create_card
Creates a new card for the specified board.
Source code in pyfocalboard/api.py
556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 |
|
create_category
create_category(team_id: str, user_id: str, category: CategoryBody) -> Category
Create a category for boards
Source code in pyfocalboard/api.py
731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 |
|
create_subscription
create_subscription(block: Block, user_id: str) -> Subscription
Creates a subscription to a block for a user. The user will receive change notifications for the block.
Source code in pyfocalboard/api.py
830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 |
|
delete_block
delete_block(board_id: str, block_id: str) -> None
Deletes a block
Source code in pyfocalboard/api.py
158 159 160 161 162 163 164 165 166 167 |
|
delete_board
delete_board(board_id: str) -> None
Removes a board
Source code in pyfocalboard/api.py
288 289 290 291 292 293 294 295 296 297 |
|
delete_boards_and_blocks
delete_boards_and_blocks(board_ids: list[str], block_ids: list[str]) -> None
Deletes boards and blocks
Source code in pyfocalboard/api.py
514 515 516 517 518 519 520 521 522 523 524 525 526 |
|
delete_category
delete_category(team_id: str, category_id: str) -> None
Delete a category
Source code in pyfocalboard/api.py
765 766 767 768 769 770 771 772 773 774 |
|
delete_member
delete_member(board_id: str, user_id: str) -> None
Deletes a member from a board
Source code in pyfocalboard/api.py
404 405 406 407 408 409 410 411 412 413 414 415 416 417 |
|
delete_subscriptions
delete_subscriptions(block_id: str, user_id: str) -> None
Deletes a subscription a user has for a a block. The user will no longer receive change notifications for the block.
Source code in pyfocalboard/api.py
849 850 851 852 853 854 855 856 857 858 |
|
duplicate_block
duplicate_block(board_id: str, block_id: str) -> None
Returns the new created blocks
Source code in pyfocalboard/api.py
169 170 171 172 173 174 175 176 177 178 179 180 |
|
duplicate_board
duplicate_board(board_id: str) -> BoardAndBlocks
Returns the new created board and all the blocks
Source code in pyfocalboard/api.py
361 362 363 364 365 366 367 368 369 370 371 372 |
|
get_blocks
get_blocks(board_id: str, parent_id: str | None = None, type: str | None = None) -> list[Block]
Returns team boards
Source code in pyfocalboard/api.py
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 |
|
get_board
get_board(board_id: str) -> Board
Returns a board
Source code in pyfocalboard/api.py
249 250 251 252 253 254 255 256 257 258 |
|
get_boards
get_boards(team_id: str) -> list[Board]
Returns team boards
Source code in pyfocalboard/api.py
236 237 238 239 240 241 242 243 244 245 246 247 |
|
get_card
get_card(card_id: str) -> Card
Fetches the specified card.
Source code in pyfocalboard/api.py
545 546 547 548 549 550 551 552 553 554 |
|
get_cards
get_cards(board_id: str, page: int = 0, per_page: int = 100) -> list[Card]
Fetches cards for the specified board.
Source code in pyfocalboard/api.py
529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 |
|
get_category_boards
get_category_boards(team_id: str) -> list[Category]
Gets the user's board categories
Source code in pyfocalboard/api.py
718 719 720 721 722 723 724 725 726 727 728 729 |
|
get_channel
get_channel(team_id: str, channel_id: str) -> Channel
Returns the requested channel
Source code in pyfocalboard/api.py
875 876 877 878 879 880 881 882 883 884 885 886 |
|
get_file
get_file(team_id: str, board_id: str, filename: str) -> bytes
Returns the contents of an uploaded file
Source code in pyfocalboard/api.py
889 890 891 892 893 894 895 896 897 898 899 |
|
get_me
get_me() -> User
Returns the currently logged-in user
Source code in pyfocalboard/api.py
682 683 684 685 686 687 688 689 690 691 |
|
get_members_for_board
get_members_for_board(board_id: str) -> list[Member]
Returns the members of the board
Source code in pyfocalboard/api.py
321 322 323 324 325 326 327 328 329 330 331 332 |
|
get_my_memberships
get_my_memberships() -> list[Member]
Returns the currently users board memberships
Source code in pyfocalboard/api.py
704 705 706 707 708 709 710 711 712 713 714 715 |
|
get_sharing
get_sharing(board_id: str) -> Sharing
Returns sharing information for a board
Source code in pyfocalboard/api.py
334 335 336 337 338 339 340 341 342 343 344 345 |
|
get_statistics
get_statistics() -> BoardsStatistics
Fetches the statistic of the server.
Source code in pyfocalboard/api.py
918 919 920 921 922 923 924 925 926 927 |
|
get_subscriptions
get_subscriptions(subscriber_id: str) -> list[Subscription]
Gets subscriptions for a user.
Source code in pyfocalboard/api.py
817 818 819 820 821 822 823 824 825 826 827 828 |
|
get_team
get_team(team_id: str) -> Team
Returns information of the root team
Source code in pyfocalboard/api.py
602 603 604 605 606 607 608 609 610 611 |
|
get_team_users
get_team_users(team_id: str, search: str | None = None, exclude_bots: bool = False) -> list[User]
Returns team users
Source code in pyfocalboard/api.py
613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 |
|
get_teams
get_teams() -> list[Team]
Returns information of all the teams
Source code in pyfocalboard/api.py
591 592 593 594 595 596 597 598 599 600 |
|
get_templates
get_templates(team_id: str) -> list[Board]
Returns team templates
Source code in pyfocalboard/api.py
644 645 646 647 648 649 650 651 652 653 654 655 |
|
get_user
get_user(user_id: str) -> User
Returns a user
Source code in pyfocalboard/api.py
693 694 695 696 697 698 699 700 701 702 |
|
get_user_config
get_user_config() -> list[UserPreference]
Returns an array of user preferences
Source code in pyfocalboard/api.py
776 777 778 779 780 781 782 783 784 785 |
|
get_users
get_users(user_ids: list[str]) -> list[User]
Returns a user list
Source code in pyfocalboard/api.py
803 804 805 806 807 808 809 810 811 812 813 814 |
|
insert_boards_and_blocks
Creates new boards and blocks
Source code in pyfocalboard/api.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 |
|
join_board
join_board(board_id: str) -> None
Become a member of a board
Source code in pyfocalboard/api.py
299 300 301 302 303 304 305 306 307 308 |
|
leave_board
leave_board(board_id: str) -> None
Remove your own membership from a board
Source code in pyfocalboard/api.py
310 311 312 313 314 315 316 317 318 319 |
|
login
login(auth: LoginRequest)
Login user
Source code in pyfocalboard/api.py
930 931 932 933 934 935 936 937 938 939 940 941 |
|
logout
logout()
Logout user
Source code in pyfocalboard/api.py
943 944 945 946 947 948 949 950 951 |
|
onboard
onboard(team_id: str) -> Onboarding
Onboards a user on Boards.
Source code in pyfocalboard/api.py
631 632 633 634 635 636 637 638 639 640 641 642 |
|
patch_block
patch_block(board_id: str, block_id: str, block: BlockBody, disable_notify: bool = False) -> None
Partially updates a block
Source code in pyfocalboard/api.py
100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 |
|
patch_blocks
patch_blocks(board_id: str, block_ids: list[str], blocks: list[BlockBody], disable_notify: bool = False) -> None
Partially updates batch of blocks
Source code in pyfocalboard/api.py
137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 |
|
patch_board
Partially updates a board
Source code in pyfocalboard/api.py
274 275 276 277 278 279 280 281 282 283 284 285 286 |
|
patch_boards_and_blocks
patch_boards_and_blocks(board_ids: list[str], boards: list[BoardBody], block_ids: list[str], blocks: list[BlockBody]) -> None
Patches a set of related boards and blocks
Source code in pyfocalboard/api.py
482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 |
|
patch_card
Patches the specified card.
Source code in pyfocalboard/api.py
573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 |
|
post_sharing
post_sharing(board_id: str, sharing: SharingBody) -> Sharing
Sets sharing information for a board
Source code in pyfocalboard/api.py
347 348 349 350 351 352 353 354 355 356 357 358 359 |
|
search_all_boards
search_all_boards(query: str = '') -> list[Board]
Returns the boards that match with a search term
Source code in pyfocalboard/api.py
194 195 196 197 198 199 200 201 202 203 204 205 206 |
|
search_boards
search_boards(team_id: str, query: str = '') -> list[Board]
Returns the boards that match with a search term in the team
Source code in pyfocalboard/api.py
208 209 210 211 212 213 214 215 216 217 218 219 220 |
|
search_linkable_boards
search_linkable_boards(team_id: str, query: str = '') -> list[Board]
Returns the boards that match with a search term in the team and the user has permission to manage members
Source code in pyfocalboard/api.py
222 223 224 225 226 227 228 229 230 231 232 233 234 |
|
search_my_channels
search_my_channels(team_id: str, search: str = '') -> list[Channel]
Returns the user available channels
Source code in pyfocalboard/api.py
861 862 863 864 865 866 867 868 869 870 871 872 873 |
|
undelete_block
undelete_block(board_id: str, block_id: str) -> None
Undeletes a block
Source code in pyfocalboard/api.py
182 183 184 185 186 187 188 189 190 191 |
|
undelete_board
undelete_board(board_id: str) -> None
Undeletes a board
Source code in pyfocalboard/api.py
444 445 446 447 448 449 450 451 452 453 |
|
update_blocks
update_blocks(board_id: str, blocks: list[Block], disable_notify: bool = False) -> None
Insert blocks. The specified IDs will only be used to link blocks with existing ones, the rest will be replaced by server generated IDs
Source code in pyfocalboard/api.py
119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 |
|
update_board_category
update_board_category(team_id: str, board_id: str, category_id: str) -> None
Set the category of a board
Source code in pyfocalboard/api.py
431 432 433 434 435 436 437 438 439 440 441 442 |
|
update_category
update_category(team_id: str, user_id: str, category_id: str, category: CategoryBody) -> Category
Create a category for boards
Source code in pyfocalboard/api.py
747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 |
|
update_member
update_member(board_id: str, user_id: str, member: MemberBody) -> Member
Updates a board member
Source code in pyfocalboard/api.py
390 391 392 393 394 395 396 397 398 399 400 401 402 |
|
update_user_config
update_user_config(user_id: str, user_preference: UserPreference) -> list[UserPreference]
Updates user config
Source code in pyfocalboard/api.py
787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 |
|
upload_file
upload_file(team_id: str, board_id: str, file: bytes) -> FileUploadResponse
Upload a binary file, attached to a root block
Source code in pyfocalboard/api.py
901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 |
|