Hi , Iam trying to use the pact js trial version b...
# pact-js
c
Hi , Iam trying to use the pact js trial version broker , in my test code , can some one tell me how I can use pact broker with token instead of user name and password ? in this code
Copy code
"test:publish": "pact-broker publish /pacts --consumer-app-version=\"$(npx absolute-version)\" --auto-detect-version-properties --broker-base-url=<https://ysi5tc076m.execute-api.eu-west-2.amazonaws.com:443> --broker-username user --broker-password passxx"
y
Hey, Not sure what this is
pact js trial version broker
Could you clarify? Regarding usage of the pact-cli, see our docs If it is is the OSS Pact Broker • https://github.com/pact-foundation/pact-broker-dockerhttps://github.com/pact-foundation/pact-broker It only supports basic auth mechanisms.
Basic auth parameters can be specified using the
$PACT_BROKER_USERNAME
and
$PACT_BROKER_PASSWORD
environment variables, or the
-u
or
--broker-username
and
-p
or
--broker-password
parameters.
If it is a Pactflow.io broker
Authentication using a bearer token can be specified using the environment variable
$PACT_BROKER_TOKEN
or the
-k
or
--broker-token
parameters. This bearer token authentication is used by PactFlow and is not available in the OSS Pact Broker, which only supports basic auth.
c
using
--broker-toke I was able to connect  thanks
m
Just remember that Pact is free and open source. Pactflow is the commercial product