GithubHelp home page GithubHelp logo

Comments (3)

kahmali avatar kahmali commented on June 27, 2024

Hey Satya,

  1. This is definitely something that needs to be added to Restivus. I'm sure you're already aware of the http-publish package that has this functionality. I have a few other things that are higher priorities for me (e.g., additional testing, route/endpoint versioning, and JSON PATCH support), but if someone wants to add it I will gladly work on hashing out an acceptable API with them or I will happily accept a pull request if someone would like to be extra ambitious. I just know that it's going to take a couple of weeks of work to design and implement a clean API that plays nicely with everything else, and I need those other features I named for my own API asap. I went ahead and added the feature to the roadmap, but it may be more than a month before I get around to implementing this.
  2. I've used Meteor methods in multiple endpoints, including authenticated endpoints. In my situation, I'm calling through to the method from within the endpoint. Are you talking about just applying the entire Meteor method as the endpoint function? That I haven't tried. If there is an easy way to add this to the API I will do it, but otherwise it will probably be fairly low priority since it's probably only saving a single line of code to call through to the method from within the endpoint (if I understand you correctly). Here's an example of what I do that works with authenticated endpoints:
Restivus.addRoute 'test', authRequired: true,
  get: ->
    Meteor.call('someMeteorMethod', @userId, arg2)

from meteor-restivus.

stubailo avatar stubailo commented on June 27, 2024

Working on a package that has this as its main feature here: https://github.com/stubailo/meteor-rest

Hoping to have a first version out on Tuesday, but until then here is a hackpad with design and discussion: https://meteor.hackpad.com/Meteor-Hack-Week-REST-APIs-with-Meteor-XK2NNXqhUvj

from meteor-restivus.

kahmali avatar kahmali commented on June 27, 2024

@stubailo's simple:rest package (referenced above) is designed specifically for this, so I have no plans to provide any additional functionality for it in Restivus. I'm open to debate as always, but I'm going to go ahead and close this for now.

from meteor-restivus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.