Yes you have to pay to use motorway just pull in at border and check in with your credit card and away you go then overhead cameras charge you as you go under them. You can also use the N125 and this us free all the way although slower but runs the length of Portugal East to west a regards Garry flatpackchicken
It is a very straightforward procedure on entering Portugal on the A22, pull into the well signposted lay bye, pull up to the automatic bays, insert a credit card and your registration is recorded and a printed record is produced, it is important to keep this as proof.
There is no method of post payment for the electronic toll motorways in Portugal, this registration process covers you for a month but note that there are also some motorways in Portugal that still use the old toll booth system not covered by this and I do not think that they will accept foreign credit cards.
The toll system does not start until after junction 17(second exit) upto then it is free.
I have done this registration process several times and have yet to have any deductions made but as long as you have the receipt you are covered, I have been stopped and checked and they do keep records.