Hello, We are implementing contract testing for m...
# pact-broker
p
Hello, We are implementing contract testing for mobile apps. To perform the record release & record support ended for multiple supported versions for mobile apps. How do we get the list of production versions from pact broker for a specific participant. In our case there are multiple active versions on production but we want to keep n-3 versions for the contract validation. As per our finding we can use below APIs to get the supported versions from pact broker but it will require some custom code to be written to get from the APIs. To get environment ID: http://localhost/environments/ To get the currently supported version: http://localhost/environments/{envIdFromAboveAPIResponse}/released-versions/currently-supported
3
b
There's no endpoint currently to get only the versions for a specific pacticipant. You'll need to call the endpoint you mentioned, and then filter in code.
Your use case of supporting a fixed number of versions is one I had considered supporting properly. Could you raise a feature request at pact.canny.io please?
p
Sure @Beth (pactflow.io/Pact Broker/pact-ruby), Thank you for your response.
b
@Prerit Jain thanks. I actually meant to raise a feature to automatically limit the number of currently supported versions.
You're just asking for this api as a means to an end. Better to solve the underlying problem.
p
Sure Beth, I will raise that too.