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

Introduce endpoint name #129

Closed
mingard opened this issue Aug 10, 2016 · 1 comment
Closed

Introduce endpoint name #129

mingard opened this issue Aug 10, 2016 · 1 comment
Assignees

Comments

@mingard
Copy link
Contributor

mingard commented Aug 10, 2016

Endpoints can have any route, meaning referring to them by a key as we require in Publish (dadi/publish#497) is not possible.

A temporary solution is to presume that the second param is the name of the endpoint:

/1.0/foo`

But in some cases they can contain more params:

1.0/database/foo/far

As the path can be anything, and the search feature in publish requires the name of the endpoint in order to run a lookup to see if it exists, we need a key/name.

module.exports.model = {
  settings: {
    name: "foo",
    displayName: "Foo Bar",
    cache: true,
    authenticate: false
  }
}
@jimlambie
Copy link
Contributor

Adding a name is already possible with displayName. I will add name, deriving it from the endpoint filename: {endpointName}.js

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

No branches or pull requests

3 participants