joe
joe

Reputation: 9503

Programy chatbot executes Django command

I am studying the way to integrate programy to my Django application. First thing I would like to see is chatbot be able to execute Django-command. For example

I: How many orders are created today?
bot: They are {{ Order.objects.filter(...).count() }} orders

When I look at the document. It mentions only AIML, but does not mention anything about execute further command.

Possible workaround:
It seems to be impossible since <set>, <get> tags are static and programy has to compile and loaded into the memory before bot start conversation.

Drawback:
Doing the pre-queries and set the variable. Bot will present the outdated value.

Question:
How do I let bot execute Django by itself?

Upvotes: 1

Views: 56

Answers (1)

v25
v25

Reputation: 7631

According to the documenation for Program-Y it does have support for an External REST Service.

If you had a Django application which presented a REST API then Program-Y should hook straight into it.

Upvotes: 1

Related Questions