Oleksandr.Boiko
10/10/2025, 8:11 AMMatt (pactflow.io / pact-js / pact-go)
but it’s not clear to us how the contract matching is done between consumer versions, provider versions, and different environments.By default, we match against the latest version, and any deployed or released version of the reciprocal of the integration. e.g. If you publish version
abc123 of application A (in an A -> B relationship)
Further, if the latest version of B is xyz098, and version abab2323 is deployed to staging and version baba6565 is deployed to prod , then we check if abc123 is compatible with:
1. The most recent version of B (xyz098)
2. All deployed/released versions
a. abab2323 (staging)
b. baba6565 (prod)
And vice versa.
When you call can-i-deploy for version that doesn’t have a compatibily matrix entry, we perform a comparison on demand. Use the polling arguments to wait for a result (usually a few seconds).