altium_api
Public API for Altium design data access.
Project Data Loading
ProjectData
Complete design data snapshot for a project.
Exposes only the main design collections: components, nets, and variants.
components
property
components: list[Component]
Get all components in the project.
Returns:
| Type | Description |
|---|---|
list[Component]
|
List of Component objects |
nets
property
nets: list[Net]
variants
property
variants: list[Variant]
load_project_data
load_project_data(context: ExecutionContext, input_parameters: dict) -> ProjectData
Load project design data for the current execution.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
context
|
ExecutionContext
|
Execution context for the current run. |
required |
input_parameters
|
dict
|
Input parameters provided for the run. |
required |
Returns:
| Type | Description |
|---|---|
ProjectData
|
Project data with components, nets, and variants. |
get_project_parameters
get_project_parameters(context: ExecutionContext, input_parameters: dict) -> list[Parameter]
Load project parameters for the current execution.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
context
|
ExecutionContext
|
Execution context for the current run. |
required |
input_parameters
|
dict
|
Input parameters provided for the run. |
required |
Returns:
| Type | Description |
|---|---|
list[Parameter]
|
Project parameters. |
Classes
Component
A logical schematic component composed of one or more parts.
Exposes essential component properties: design_component_id, designator, parameters, name, description, pins, and nets.
design_component_id
property
design_component_id: str
Get the design component identifier.
Returns:
| Type | Description |
|---|---|
str
|
Design component ID string |
library_component_id
property
library_component_id: Optional[str]
Get the library component identifier.
Returns:
| Type | Description |
|---|---|
Optional[str]
|
Library component ID string, or None if not available |
description
property
description: str
Get the component description from the Description parameter.
Returns:
| Type | Description |
|---|---|
str
|
Component description string |
designator
property
designator: str
Get the component designator (logical designator).
Returns:
| Type | Description |
|---|---|
str
|
Designator string (e.g., "R1", "U5", "C10") |
name
property
name: str
Get the component name.
Returns:
| Type | Description |
|---|---|
str
|
Component name string |
nets
property
nets: list[Net]
parameters
property
parameters: list[Parameter]
Get all parameters of the component.
Returns:
| Type | Description |
|---|---|
list[Parameter]
|
List of Parameter objects |
pins
property
pins: list[Pin]
type
property
type: str
Get the component type.
Returns:
| Type | Description |
|---|---|
str
|
Component type string. |
variant
property
variant: Optional[str]
Get the variant name of the component.
Returns:
| Type | Description |
|---|---|
Optional[str]
|
Variant name string, or None if no variant is assigned |
Parameter
A name/value parameter attached to a design object.
Exposes parameter name and value.
name
property
name: str
Get the parameter name.
Returns:
| Type | Description |
|---|---|
str
|
Parameter name string (e.g., "Comment", "Value", "Voltage") |
value
property
value: str
Get the parameter value.
Returns:
| Type | Description |
|---|---|
str
|
Parameter value string |
Pin
An electrical pin on a schematic component.
Exposes essential pin properties: design_pin_id, name, number, and links to the owning component and connected net.
design_pin_id
property
design_pin_id: str
Get the design pin identifier of the pin.
Returns:
| Type | Description |
|---|---|
str
|
Design pin ID string |
component
property
component: Optional[Component]
Get the component this pin belongs to.
Returns:
| Type | Description |
|---|---|
Optional[Component]
|
The owning Component, or None if not resolved. |
description
property
description: Optional[str]
Get the pin description.
Returns:
| Type | Description |
|---|---|
Optional[str]
|
Pin description string, or None if not provided. |
electrical_type
property
electrical_type: Optional[str]
Get the pin electrical type.
Returns:
| Type | Description |
|---|---|
Optional[str]
|
Electrical type string, or None if not provided. |
functions
property
functions: list[str]
Get the pin functions.
Returns:
| Type | Description |
|---|---|
list[str]
|
List of function names reported by the design data service. |
name
property
name: str
Get the functional name of the pin.
Returns:
| Type | Description |
|---|---|
str
|
Pin name string (e.g., "VCC", "GND", "D+") |
full_name
property
full_name: str
Get the full name of the pin.
Returns:
| Type | Description |
|---|---|
str
|
Full pin name string, or an empty string if not provided. |
net
property
net: Optional[Net]
Get the net this pin is connected to.
Returns:
| Type | Description |
|---|---|
Optional[Net]
|
The connected Net, or None if not resolved. |
number
property
number: str
Get the pin number.
Returns:
| Type | Description |
|---|---|
str
|
Pin number string as shown on the component symbol |
parameters
property
parameters: list[Parameter]
Get the pin parameters.
Returns:
| Type | Description |
|---|---|
list[Parameter]
|
List of Parameter objects attached to the pin. |
propagation_delay
property
propagation_delay: Optional[float]
Get the pin propagation delay.
Returns:
| Type | Description |
|---|---|
Optional[float]
|
Propagation delay value, or None if not provided. |
Net
A schematic net grouping all electrically connected pins.
Exposes essential net properties: design_net_id, name, parameters, pins, and net_items.
design_net_id
property
design_net_id: str
Get the design net identifier.
Returns:
| Type | Description |
|---|---|
str
|
Design net ID string |
diff_pair
property
diff_pair: Optional[NetDiffPair]
Get the differential pair metadata, if present.
Returns:
| Type | Description |
|---|---|
Optional[NetDiffPair]
|
NetDiffPair, or None if absent. |
name
property
name: str
Get the net name.
Returns:
| Type | Description |
|---|---|
str
|
Net name string (e.g., "GND", "VCC3V3") |
net_classes
property
net_classes: list[str]
Get the net classes associated with this net.
Returns:
| Type | Description |
|---|---|
list[str]
|
List of net class names. |
net_items
property
net_items: list[NetItem]
Get all net items (ports, labels) belonging to this net.
Returns:
| Type | Description |
|---|---|
list[NetItem]
|
List of NetItem objects |
parameters
property
parameters: list[Parameter]
pins
property
pins: list[Pin]
rules
property
rules: list[NetRule]
Get the rules attached to this net.
Returns:
| Type | Description |
|---|---|
list[NetRule]
|
List of NetRule objects. |
NetItem
A named port or net label belonging to a net.
Exposes essential net item properties: design_net_item_id, kind, and port_name.
design_net_item_id
property
design_net_item_id: str
Get the design net item identifier.
Returns:
| Type | Description |
|---|---|
str
|
Design net item ID string |
kind
property
kind: str
Get the kind of net item.
Returns:
| Type | Description |
|---|---|
str
|
Kind string (e.g., "Port", "NetLabel", "PowerSymbol") |
port_name
property
port_name: str
Get the port name of the net item.
Returns:
| Type | Description |
|---|---|
str
|
Port name string |
NetRule
A rule attached to a net.
attributes
property
attributes: list[NetRuleAttribute]
Get rule attributes.
Returns:
| Type | Description |
|---|---|
list[NetRuleAttribute]
|
List of NetRuleAttribute objects |
name
property
name: str
Get the rule name.
Returns:
| Type | Description |
|---|---|
str
|
Rule name string. |
NetRuleAttribute
A single name/value attribute attached to a net rule.
name
property
name: str
Get the attribute name.
Returns:
| Type | Description |
|---|---|
str
|
Attribute name string. |
value
property
value: str
Get the attribute value.
Returns:
| Type | Description |
|---|---|
str
|
Attribute value string. |
NetDiffPair
Differential pair metadata attached to a net.
negative_net
property
negative_net: str
Get the negative net name.
Returns:
| Type | Description |
|---|---|
str
|
Net name used as the negative side of the differential pair. |
positive_net
property
positive_net: str
Get the positive net name.
Returns:
| Type | Description |
|---|---|
str
|
Net name used as the positive side of the differential pair. |
Variant
A Design variant defined in the project.
Exposes variant name and GUID.
name
property
name: str
Get the variant name.
Returns:
| Type | Description |
|---|---|
str
|
Variant name string (e.g., "Production", "Prototype") |
variant_guid
property
variant_guid: str
Get the variant GUID.
Returns:
| Type | Description |
|---|---|
str
|
Variant GUID string |