How to create the API depends on your set-up. Generally you would have one application (redmine plugin) get some data (probably json/xml encoded) from another application (external website) by going to a particular URL.
so your client (redmine) would do a web request something like: (pseudocode)
response = curl_get('https://my.external-app.com/api/ticket?id='+ticketID)
external_people = json_decode(response)
This is basically making a web-request to some url and de-serialising the response so that you have data-structure (array or object) that you can easily use in your code.
Your external webapp would need to respond with the correct data, the easiest might be to place a script at /api/ticket that fetches the required data from your database and prints it out in some serialised format (xml/json):
ticket_id = http_request_parameter('id')
// should do some validation here to prevent SQL-injection
...
// get the ticket details matching the id
sql_result = db_query_result("SELECT user_id from `issues` where id=" + ticket_id)
//send the result
print json_encode(sql_result)
Once you have this working you may want to add API-keys so that only authorised applications can retrieve the data.