Placing API key in

I posting data to the URL on the server. I am using for posting the data. They provided me API key. Where should I put this API key, should it be in username or password params?
Can you share the example if you have used it?

This is something you should already know, or should have been told to you or been part of documentation.

Often it’s placed in a header with a certain name, but whether that’s true for this API and what that header might be you would need to find out.

Yes, they provide me Endpoint: and x-API-key:. But I don’t where to put in scripting.

See the documentation, under JythonHttpClient Methods > Parameters. - Ignition User Manual 8.1 - Ignition Documentation

One of the optional parameters is a headers dictionary you can supply to the POST call.