Authentication & Authorization

All SendClean API requests require authentication to ensure security and proper access control. Authentication is performed using a combination of credentials that uniquely identify your account and verify your permissions.

Required Authentication Parameters

ParameterTypeRequiredDescription
owner_idStringYesYour unique account identifier provided during account creation. This ID is permanent and identifies your SendClean account.
tokenStringYesYour API authentication token. This is a secret key that verifies your identity. Keep this secure and never share it publicly.
smtp_user_nameStringConditionalRequired for email sending operations. This identifies which SMTP user credentials to use for sending the email.

Security Best Practices

Follow these practices to keep your SendClean API credentials secure.

Best practiceWhat to doWhy it matters
Keep tokens server-sideStore your API token only on your server. Do not include it in browser JavaScript, mobile apps, or any code that runs on user devices.Client-side code can be inspected, which can expose your token publicly.
Use HTTPSSend all API requests over HTTPS.HTTPS encrypts credentials and request data in transit.
Rotate tokens periodicallyRotate API tokens every 90 days using the token management APIs.Regular rotation reduces the impact of a leaked or compromised token.
Use environment variablesStore owner_id, token, and smtp_user_name in environment variables or a secure configuration system.This keeps credentials out of your source code and version control.
Implement rate limitingMonitor API usage and apply rate limits in your application.Rate limiting helps prevent abuse and unexpected traffic spikes.

Did this page help you?