When and where should I replace tokens on a custom path for metatag context? I have custom tokens defined in hook_token_info() and hook_tokens().  I need these tokens to populate metatag data for the metagag module on a custom path.  I have the context module installed as well.

The path routes to a callback that loads the object I need to pass to token_replace().

My question is when and where do I call token_replace() so the tokens are available to metatag context on page load?
The correct place to specify the replace data was in hook_tokens().  I did not follow the original tutorial correctly and thought since my tokens were not available I was in the wrong place.

I ended up specifying my tokens as the current-page type.  After I did that, they displayed and I can now use them for my metatags.

As a side note, I did discover you need to run cron after you make changes to hook_token_info().