feat: add spans in client

This commit is contained in:
firedotguy
2026-02-28 23:48:26 +03:00
parent ec58bae1e8
commit 86a378b613
5 changed files with 23 additions and 5 deletions

View File

@@ -5,8 +5,10 @@ from itd.request import fetch
from itd.enums import PostsTab
from itd.models.post import NewPoll
def create_post(token: str, content: str | None = None, wall_recipient_id: UUID | None = None, attachment_ids: list[UUID] = [], poll: NewPoll | None = None):
def create_post(token: str, content: str | None = None, spans: list[dict] = [], wall_recipient_id: UUID | None = None, attachment_ids: list[UUID] = [], poll: NewPoll | None = None):
data: dict = {'content': content or ''}
if spans:
data['spans'] = spans
if wall_recipient_id:
data['wallRecipientId'] = str(wall_recipient_id)
if attachment_ids: