Contracts define the policies and services that get applied
to EPGs. Contracts can be used for redirecting service to
a Layer 4 to Layer 7 device, assigning QoS values, and
controlling the traffic flow between EPGs. EPGs can only
communicate with other EPGs based on contract rules.
Contracts specify the protocols and ports allowed
between EPGs. If there is no contract, inter-EPG
communication is disabled by default. For intra-EPG
communication, no contract is required as this traffic is
always allowed by default. The relationship between an
EPG and a contract can be either a consumer or a
provider. EPG providers expose contracts with which a
consumer EPG must comply. When an EPG consumes a
contract, the endpoints in the consuming EPG can
initiate communication with any endpoint from the
provider EPG. Figure 9-7 displays this contractual
relationship between providing and consuming EPGs.
Figure 9-7 Cisco ACI Application Profiles and
Contracts
Filters are the objects that define protocols and port
numbers used in contracts. Filter objects can contain
multiple protocols and ports, and contracts can consume
multiple filters.
APIC REST API
As mentioned previously, the APIC REST API is a
programmatic interface that uses the REST architecture.
The API accepts and returns HTTP or HTTPS messages
that contain JSON or XML documents. Any
programming language can be used to generate the