To successfully publish your smart contract souce code on Avascan, you need to take a few simple steps.
If you are deploying your token or smart contract using Remix, the compiler automatically uploads the source code to IPFS and appends its hash as metadata at the end of the code before deploying. The code includes all the comments and we can automatically verify it by pulling the code from IPFS, compiling and publish it if it's a perfect match.
However, if you do not deploy using Remix, chances are you didn't upload the source code to IPFS. We can still verify it, we won't be able to confirm if it's a perfect match, that is code and comments.
To verify a smart contract you just need to execute the following command:
curl -X POST -H 'Content-type: application/json' -d '$BODY' https://avascan.info/api/v1/verify-contract