Skip to content

Issue Operations

Operations for managing issues and issue-related data.

API Reference

IssueOperations

IssueOperations(client: Client)

Bases: BaseOperations, IssueOperationsMixin

Class to handle all operations related to issues.

Provides functionality to create, retrieve, list, and solve issues associated with meetings and users.

Methods:

  • details

    Retrieve detailed information about a specific issue.

  • list

    List issues filtered by user or meeting.

  • complete

    Mark an issue as completed/solved.

  • update

    Update an existing issue.

  • create

    Create a new issue in the system.

  • create_many

    Create multiple issues in a best-effort manner.

Functions

details
details(issue_id: int) -> IssueDetails

Retrieve detailed information about a specific issue.

Parameters:

  • issue_id (int) –

    Unique identifier of the issue

Returns:

  • IssueDetails

    An IssueDetails model instance containing detailed information

  • IssueDetails

    about the issue

Example
client.issue.details(123)
# Returns: IssueDetails(id=123, title='Issue Title',
#          created_at='2024-06-10', ...)
list
list(user_id: int | None = None, meeting_id: int | None = None) -> list[IssueListItem]

List issues filtered by user or meeting.

Parameters:

  • user_id (int | None, default: None ) –

    Unique identifier of the user (optional)

  • meeting_id (int | None, default: None ) –

    Unique identifier of the meeting (optional)

Returns:

  • list[IssueListItem]

    A list of IssueListItem model instances matching the filter criteria

Raises:

  • ValueError

    When both user_id and meeting_id are provided

Example
# List issues for current user
client.issue.list()
# Returns: [IssueListItem(id=1, title='Issue 1', ...), ...]

# List issues for specific meeting
client.issue.list(meeting_id=456)
# Returns: [IssueListItem(id=2, title='Issue 2', ...), ...]
complete
complete(issue_id: int) -> IssueDetails

Mark an issue as completed/solved.

Parameters:

  • issue_id (int) –

    Unique identifier of the issue to be completed

Returns:

  • IssueDetails

    The updated IssueDetails

Example
completed_issue = client.issue.complete(123)
print(completed_issue.completed_at)
update
update(issue_id: int, title: str | None = None, notes: str | None = None) -> IssueDetails

Update an existing issue.

Parameters:

  • issue_id (int) –

    The ID of the issue to update

  • title (str | None, default: None ) –

    New title for the issue (optional)

  • notes (str | None, default: None ) –

    New notes for the issue (optional)

Returns:

  • IssueDetails

    The updated IssueDetails

Raises:

  • ValueError

    If no update fields are provided

Example
updated = client.issue.update(123, title="New Title")
print(updated.title)
create
create(meeting_id: int, title: str, user_id: int | None = None, notes: str | None = None) -> CreatedIssue

Create a new issue in the system.

Parameters:

  • meeting_id (int) –

    Unique identifier of the associated meeting

  • title (str) –

    Title/name of the issue

  • user_id (int | None, default: None ) –

    Unique identifier of the issue owner (defaults to current user)

  • notes (str | None, default: None ) –

    Additional notes or description for the issue (optional)

Returns:

  • CreatedIssue

    A CreatedIssue model instance containing the newly created issue details

Example
client.issue.create(
    meeting_id=123,
    title="New Issue",
    notes="This is a detailed description"
)
# Returns: CreatedIssue(id=456, title='New Issue', meeting_id=123, ...)
create_many
create_many(issues: list[dict[str, Any]]) -> BulkCreateResult[CreatedIssue]

Create multiple issues in a best-effort manner.

Processes each issue sequentially to avoid rate limiting. Failed operations are captured and returned alongside successful ones.

Parameters:

  • issues (list[dict[str, Any]]) –

    List of dictionaries containing issue data. Each dict should have: - meeting_id (required): ID of the associated meeting - title (required): Title of the issue - user_id (optional): ID of the issue owner (defaults to current user) - notes (optional): Additional notes for the issue

Returns:

  • BulkCreateResult[CreatedIssue]

    BulkCreateResult containing: - successful: List of CreatedIssue instances for successful creations - failed: List of BulkCreateError instances for failed creations

Example
result = client.issue.create_many([
    {"meeting_id": 123, "title": "Issue 1", "notes": "Details"},
    {"meeting_id": 123, "title": "Issue 2", "user_id": 456}
])

print(f"Created {len(result.successful)} issues")
for error in result.failed:
    print(f"Failed at index {error.index}: {error.error}")

Async Version

The async version AsyncIssueOperations provides the same methods as above, but with async/await support:

AsyncIssueOperations

AsyncIssueOperations(client: AsyncClient)

Async class to handle all operations related to issues.

Async Usage

All methods have the same parameters and return types as their sync counterparts. Simply add await before each method call.

Usage Examples

from bloomy import Client

with Client(api_key="your-api-key") as client:
    # Create a new issue
    issue = client.issue.create(
        meeting_id=123,
        title="Server performance degradation",
        notes="Response times increased by 50% during peak hours"
    )

    # Get issue details
    details = client.issue.details(issue_id=issue.id)
    print(f"Created: {details.created_at}")
    print(f"Meeting: {details.meeting_title}")
    print(f"Assigned to: {details.user_name}")

    # List issues for current user
    my_issues = client.issue.list()

    # List issues for a specific meeting
    meeting_issues = client.issue.list(meeting_id=123)

    # Update an issue
    updated = client.issue.update(
        issue_id=issue.id,
        title="Updated: Server performance degradation",
        notes="Added monitoring and identified bottleneck"
    )

    # Complete an issue (mark as solved)
    completed = client.issue.complete(issue_id=issue.id)
    print(f"Completed: {completed.title}")
import asyncio
from bloomy import AsyncClient

async def main():
    async with AsyncClient(api_key="your-api-key") as client:
        # Create a new issue
        issue = await client.issue.create(
            meeting_id=123,
            title="Server performance degradation",
            notes="Response times increased by 50% during peak hours"
        )

        # Get issue details
        details = await client.issue.details(issue_id=issue.id)
        print(f"Created: {details.created_at}")
        print(f"Meeting: {details.meeting_title}")
        print(f"Assigned to: {details.user_name}")

        # List issues for current user
        my_issues = await client.issue.list()

        # List issues for a specific meeting
        meeting_issues = await client.issue.list(meeting_id=123)

        # Update an issue
        updated = await client.issue.update(
            issue_id=issue.id,
            title="Updated: Server performance degradation",
            notes="Added monitoring and identified bottleneck"
        )

        # Complete an issue (mark as solved)
        completed = await client.issue.complete(issue_id=issue.id)
        print(f"Completed: {completed.title}")

asyncio.run(main())

Available Methods

Method Description Parameters Returns
details() Get detailed issue information issue_id IssueDetails
list() Get issues user_id, meeting_id list[IssueListItem]
create() Create a new issue meeting_id, title, user_id, notes CreatedIssue
create_many() Create multiple issues issues BulkCreateResult[CreatedIssue]
update() Update an existing issue issue_id, title, notes IssueDetails
complete() Mark an issue as solved issue_id IssueDetails

Issue Management

  • Issues can only be marked as solved, not deleted. Use the complete() method to close an issue.
  • The complete() method returns the updated issue details, allowing you to verify the completion.
  • Use update() to modify issue title or notes before completing.

Update Examples

from bloomy import Client

with Client(api_key="your-api-key") as client:
    # Update issue title only
    updated = client.issue.update(123, title="New Title")

    # Update issue notes only
    updated = client.issue.update(123, notes="Additional context and details")

    # Update both title and notes
    updated = client.issue.update(
        issue_id=123,
        title="Critical: Database Connection Pool Exhausted",
        notes="Increased max connections from 100 to 200"
    )
import asyncio
from bloomy import AsyncClient

async def main():
    async with AsyncClient(api_key="your-api-key") as client:
        # Update issue title only
        updated = await client.issue.update(123, title="New Title")

        # Update issue notes only
        updated = await client.issue.update(123, notes="Additional context and details")

        # Update both title and notes
        updated = await client.issue.update(
            issue_id=123,
            title="Critical: Database Connection Pool Exhausted",
            notes="Increased max connections from 100 to 200"
        )

asyncio.run(main())

Update Requirements

At least one of title or notes must be provided when calling update(). If neither is provided, a ValueError will be raised.

Bulk Operations

Creating Multiple Issues

from bloomy import Client

with Client(api_key="your-api-key") as client:
    # Create multiple issues at once
    issues = [
        {
            "meeting_id": 123,
            "title": "Server performance degradation",
            "notes": "Response times increased by 50%"
        },
        {
            "meeting_id": 123,
            "title": "Database connection pool exhausted",
            "user_id": 456,
            "notes": "Max connections reached during peak hours"
        },
        {
            "meeting_id": 789,
            "title": "Authentication service timeout"
        }
    ]

    result = client.issue.create_many(issues)

    # Check results
    print(f"Successfully created {len(result.successful)} issues")
    for issue in result.successful:
        print(f"- Issue #{issue.id}: {issue.title}")

    # Handle failures
    if result.failed:
        print(f"Failed to create {len(result.failed)} issues")
        for error in result.failed:
            print(f"- Index {error.index}: {error.error}")
            print(f"  Input: {error.input_data}")
import asyncio
from bloomy import AsyncClient

async def main():
    async with AsyncClient(api_key="your-api-key") as client:
        # Create multiple issues concurrently
        issues = [
            {
                "meeting_id": 123,
                "title": "Server performance degradation",
                "notes": "Response times increased by 50%"
            },
            {
                "meeting_id": 123,
                "title": "Database connection pool exhausted",
                "user_id": 456,
                "notes": "Max connections reached during peak hours"
            },
            {
                "meeting_id": 789,
                "title": "Authentication service timeout"
            }
        ]

        # Control concurrency with max_concurrent parameter
        result = await client.issue.create_many(issues, max_concurrent=5)

        # Check results
        print(f"Successfully created {len(result.successful)} issues")
        for issue in result.successful:
            print(f"- Issue #{issue.id}: {issue.title}")

        # Handle failures
        if result.failed:
            print(f"Failed to create {len(result.failed)} issues")
            for error in result.failed:
                print(f"- Index {error.index}: {error.error}")
                print(f"  Input: {error.input_data}")

asyncio.run(main())

Async Rate Limiting

The async version of create_many() supports a max_concurrent parameter (default: 5) to control the maximum number of concurrent requests. This helps prevent rate limiting issues when creating large batches of issues.

# Process more items concurrently for better performance
result = await client.issue.create_many(issues, max_concurrent=10)

# Process items more slowly to avoid rate limits
result = await client.issue.create_many(issues, max_concurrent=2)

Bulk Operation Best Practices

  • Best-effort approach: create_many() continues processing even if some issues fail to create
  • Check both lists: Always inspect both result.successful and result.failed to handle partial failures
  • Required fields: Each issue dict must include meeting_id and title
  • Optional fields: user_id defaults to the authenticated user if not provided
  • Error handling: Failed creations include the original input data and error message for debugging