API-key Expiration

iam using
1.To get the apikey for my id
but getting 404 error.what might be the reason.
2.if i get it how long i can use it.is there any expiration time for that?

You get 404 because there’s no API key with that ID. You have to create it first by POSTing the target member ID to /api/v1/api-keys (for example, via the Live API page or by using the cURL command from the API documentation).

API keys don’t expire automatically. If you ever need to invalidate an API key, you can simply delete it.