Get Pipeline Step Logs
get_pipeline_step_logsRetrieve logs for a Bitbucket pipeline step, using byte-range pagination for large logs. Optionally fetch logs from a specific service container by log UUID.
Instructions
Get logs for a specific pipeline step.
Raw step logs are routinely multi-MB, so only the last max_bytes (100 KiB by
default) are returned. Check the truncated flag in the response and page
through the rest with start/end if you need more.
Args: repo_slug: Repository slug pipeline_uuid: Pipeline UUID, e.g. "{adab6a1f-...}". Unlike get_pipeline_run, this endpoint is not documented to accept a build number — resolve the UUID first via get_pipeline_run if you only have a number. step_uuid: Step UUID (from get_pipeline_steps) workspace: Workspace name (optional, defaults to configured workspace) log_uuid: Optional log UUID. Omit for the main build container; pass a service container UUID to read that service's log instead. start: First byte to return (absolute, inclusive) end: Last byte to return (absolute, inclusive). start/end are an absolute byte window, not a "last N bytes" convention. max_bytes: Size of the trailing slice returned when no start/end is given (default: 100 KiB). Pass null for the whole log.
Returns:
Dict with the log content, whether it was truncated, returned_bytes
and total_bytes (null when the server did not disclose the full size)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| end | No | ||
| start | No | ||
| log_uuid | No | ||
| max_bytes | No | ||
| repo_slug | Yes | ||
| step_uuid | Yes | ||
| workspace | No | ||
| pipeline_uuid | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |