Train and Activate Model via API

I’m working on my CI/CD workflow to deploy a new instance of my Rasa X bot. I’d like to automate the training and activation of the model as part of this process.

The Rasa API has a train endpoint which requires a list of parameters that come from Rasa X. I don’t see a Rasa X train model endpoint. Is there a way to initiate the train from Rasa X via the API (same action that is taken by the Train button)?

The train button is calling POST /api/projects/default/models/jobs. Is this a supported endpoint?

Same with Activate which is calling PUT /api/projects/default/models/<model-name>/tags/production.

Those two endpoints work for me.

1 Like

Hi @stephens

Could you elaborate a little on how you got these endpoints to work?

I’m trying to do exactly the same thing, but when I try to trigger the new training via api/projects/default/models/jobs I get the error Model 'None' not found for project 'default'.

Some more detail here:

Any hints would be gratefully received, thank you!