Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add suggestion list section to the parameters of an action in the workflow #5

Closed
hadimansouri opened this issue May 10, 2020 · 1 comment

Comments

@hadimansouri
Copy link
Member

hadimansouri commented May 10, 2020

The response of the REST for a list of possible actions on an entity contains required and optional parameters needed by each action. Now it is a good idea to add a suggestion list section to this response to provide some hint for clients about needed resources by each parameter. For example:

{
   title: 'Set Fixer',
   id: set_fixer',
   .
   .
   .
   suggestions: [
        {
            title: 'Fixer',
            resource: '/api/v2/user/role/' + roleId + '/accounts',
        },
        {
            title: 'Zone Owner',
            resource: '/api/v2/user/role/' + zroleId + '/accounts',
        },
   ]
}
@hadimansouri
Copy link
Member Author

hadimansouri commented Jul 3, 2020

Improvement on the suggestion section:

suggestions:[
    {
        title: 'Fixer',
        url: '/api/v2/user/role/' + roleId + '/accounts',
        filter: {
            key: value,
            key2: value2
        },
        template: 'mustache template for example {{id}}'
    },
    {
        ...
    }
]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant