Set up users/PIN number to call

hello im looking for something for a way to add a PIN number before you call and I want to be able to see who made the call to where so basically I will have 1 phone and to make a call you will need to dial your PIN number each person should have a different PIN number and I would like it if I can add credit or minutes in other words a pay phone

I am not sure that FreePBX is well suited for this use case. At best you will have to create a lot of the code yourself to handle this behavior.

How can I do that

Learn how to write code or hire somebody that knows how to do it already? This community has a jobs section that you could post into to see if somebody is willing to work on this if you yourself don’t know how to do it.

Your request is somewhat vague.
Possibly, https://sangomakb.atlassian.net/wiki/spaces/PG/pages/26640553/Pin+Sets
will meet your needs.

If not, the paid module https://sangomakb.atlassian.net/wiki/spaces/PG/pages/34111801/PINSet+Pro
may do what you want.