aries_cloudagent.protocols.actionmenu.v1_0 package

Subpackages

Submodules

aries_cloudagent.protocols.actionmenu.v1_0.base_service module

Base action menu service classes.

class aries_cloudagent.protocols.actionmenu.v1_0.base_service.BaseMenuService(context: InjectionContext)[source]

Bases: ABC

Base action menu service interface.

abstract async get_active_menu(profile: Profile, connection: Optional[ConnRecord] = None, thread_id: Optional[str] = None) Menu[source]

Render the current menu.

Parameters
  • profile – The profile

  • connection – The active connection record

  • thread_id – The thread identifier from the requesting message.

abstract async perform_menu_action(profile: Profile, action_name: str, action_params: dict, connection: Optional[ConnRecord] = None, thread_id: Optional[str] = None) AgentMessage[source]

Perform an action defined by the active menu.

Parameters
  • profile – The profile

  • action_name – The unique name of the action being performed

  • action_params – A collection of parameters for the action

  • connection – The active connection record

  • thread_id – The thread identifier from the requesting message.

classmethod service_handler()[source]

Quick accessor for conductor to use.

aries_cloudagent.protocols.actionmenu.v1_0.controller module

Protocol controller for the action menu message family.

class aries_cloudagent.protocols.actionmenu.v1_0.controller.Controller(protocol: str)[source]

Bases: object

Action menu protocol controller.

determine_goal_codes() Sequence[str][source]

Return defined goal_codes.

async determine_roles(context: InjectionContext) Sequence[str][source]

Determine what action menu roles are defined.

aries_cloudagent.protocols.actionmenu.v1_0.driver_service module

Driver-based action menu service classes.

class aries_cloudagent.protocols.actionmenu.v1_0.driver_service.DriverMenuService(context: InjectionContext)[source]

Bases: BaseMenuService

Driver-based action menu service.

async get_active_menu(profile: Profile, connection: Optional[ConnRecord] = None, thread_id: Optional[str] = None) Menu[source]

Render the current menu.

Parameters
  • profile – The profile

  • connection – The active connection record

  • thread_id – The thread identifier from the requesting message.

async perform_menu_action(profile: Profile, action_name: str, action_params: dict, connection: Optional[ConnRecord] = None, thread_id: Optional[str] = None) AgentMessage[source]

Perform an action defined by the active menu.

Parameters
  • profile – The profile

  • action_name – The unique name of the action being performed

  • action_params – A collection of parameters for the action

  • connection – The active connection record

  • thread_id – The thread identifier from the requesting message.

aries_cloudagent.protocols.actionmenu.v1_0.message_types module

Message type identifiers for Action Menus.

aries_cloudagent.protocols.actionmenu.v1_0.routes module

Action menu admin routes.

class aries_cloudagent.protocols.actionmenu.v1_0.routes.ActionMenuFetchResultSchema(*args: Any, **kwargs: Any)[source]

Bases: OpenAPISchema

Result schema for action-menu fetch.

result

alias of MenuSchema

class aries_cloudagent.protocols.actionmenu.v1_0.routes.ActionMenuModulesResultSchema(*args: Any, **kwargs: Any)[source]

Bases: OpenAPISchema

Schema for the modules endpoint.

class aries_cloudagent.protocols.actionmenu.v1_0.routes.MenuConnIdMatchInfoSchema(*args: Any, **kwargs: Any)[source]

Bases: OpenAPISchema

Path parameters and validators for request taking connection id.

class aries_cloudagent.protocols.actionmenu.v1_0.routes.MenuJsonSchema(*args: Any, **kwargs: Any)[source]

Bases: OpenAPISchema

Matches MenuSchema but without the inherited AgentMessage properties.

class aries_cloudagent.protocols.actionmenu.v1_0.routes.PerformRequestSchema(*args: Any, **kwargs: Any)[source]

Bases: OpenAPISchema

Request schema for performing a menu action.

class aries_cloudagent.protocols.actionmenu.v1_0.routes.SendMenuSchema(*args: Any, **kwargs: Any)[source]

Bases: OpenAPISchema

Request schema for sending a menu to a connection.

aries_cloudagent.protocols.actionmenu.v1_0.routes.post_process_routes(app: aiohttp.web.Application)[source]

Amend swagger API.

async aries_cloudagent.protocols.actionmenu.v1_0.routes.register(app: aiohttp.web.Application)[source]

Register routes.

aries_cloudagent.protocols.actionmenu.v1_0.util module

Action menu utility methods.

async aries_cloudagent.protocols.actionmenu.v1_0.util.retrieve_connection_menu(connection_id: str, context: AdminRequestContext) Menu[source]

Retrieve the previously-received action menu.

async aries_cloudagent.protocols.actionmenu.v1_0.util.save_connection_menu(menu: Menu, connection_id: str, context: AdminRequestContext)[source]

Save a received action menu.