Message Structure
A minimal, multi-modal structure for exchanging content
In the Agent Communication Protocol (ACP), a Message is a sequence of ordered parts, forming complete, structured, multi-modal communications.
Message Parts
Attribute | Required | Description |
---|---|---|
content_type | Yes | The MIME type describing the format of the content |
content OR content_url | Yes | Content provided inline (content ) or via URL (content_url ) |
content_encoding | No | Encoding of the content ("plain" by default, or "base64" ) |
name | No | If present, identifies the part as an Artifact |
Artifacts
Artifacts are specialized MessageParts identified explicitly by a required name
attribute. They typically represent:
- Attachments
- Citations
- Files
- Named results
Examples
ACP Messages always consist of ordered parts. The ordering ensures content is presented or processed in the intended sequence.
Basic Text Message
Multi-modal Message with Image
Message with an Artifact
Content Delivery Methods
Inline Content
Use inline content for small, text-based, or simple data:
Referenced Content
Use referenced content (via URLs) for larger files, external resources, or when inline embedding is impractical:
Base64 Encoded Content
Use explicitly for binary data (e.g., images, documents) embedded directly:
Data Models
Artifact
inherits all validation rules from MessagePart
. Therefore, artifacts must also contain either content
or content_url
, but never both.Validation Rules
- Every part must have a
content_type
- Parts must provide either
content
orcontent_url
, but not both - MessageParts with a
name
are considered Artifacts - Parts are ordered, allowing for structured sequences
Common Content Types
Some commonly used content types include:
text/plain
: For plain text contentimage/png
,image/jpeg
: For image contentapplication/json
: For JSON dataapplication/pdf
: For PDF documentstext/html
: For HTML content
Any valid MIME type can be used as appropriate for your content.
Extensibility Feature
ACP is designed to be extensible through specialized content types:
- Schema validation via
application/json;schema=...
- Special meaning for certain types (trajectory, tool calling, etc.)
- Additional metadata for specific applications