Questions tagged [loopbackjs]

LoopBack is an open source Node.js framework built on top of Express.js optimized for mobile, web, and other devices. Connect to multiple data sources, write business logic in Node.js, glue on top of your existing services and data, build REST APIs and connect using JavaScript, iOS, and Android SDKs.

The LoopBack framework is a set of Node.js modules that you can use independently or together. An application interacts with data sources through the LoopBack model API, available locally within Node.js, remotely over REST, and via native client APIs for iOS, Android, and HTML5.

Using these APIs, apps can query databases, store data, upload files, send emails, create push notifications, register users, and perform other actions provided by data sources and services. Clients can call LoopBack APIs directly using Strong Remoting, a pluggable transport layer that enables you to provide backend APIs over REST, WebSockets, and other transports.

See also

2853 questions
1
vote
1 answer

Extending loopback models using the same collection in mongodb?

Is it possible to use the loopback-connector-mongodb and have extended loopback models use the same collection in mongodb? I'm essentially looking for the same feature as mongoose's model discriminator.
1
vote
1 answer

Where can I find / modify Loopbackjs model metadata?

As you might now, Loopbackjs framework displays a swagger-based explorer interface exposing your API endpoints and briefly explaining the methods. The problem it's that this interface it a little too much interactive. I need to provide an api-docs…
ffflabs
  • 17,166
  • 5
  • 51
  • 77
1
vote
1 answer

How to get the ExpressJS request and response object in LoopbackJS?

I am facing a problem finding the request and response objects given by ExpressJS. I made an endpoint in /server/boot/root.js like bellow. I don't want this endpoint to bind with any model. router.get('/playing/:param1/:param2',function(ctx){ …
Nur Rony
  • 7,823
  • 7
  • 38
  • 45
1
vote
2 answers

how to install Strongloop api in node.js and can use loopback

When Installing strongloop api in node.js with npm install -g strongloop command it gives error and slc file is not genrated and after that i can not use slc loopback command. Is there any solution for this errors and can use this…
1
vote
1 answer

How to extend User properly with mysql in Loopback

I am very new to loopback. I am making my first app with it and I change my datasource to MySql. my person model look like this person.json { "name": "Person", "plural": "People", "base":"User", "properties": { "firstName": { …
Nur Rony
  • 7,823
  • 7
  • 38
  • 45
1
vote
1 answer

loopback include remote method in query

I am looking for a way to include the result of a remote method when I make a query. For example: I am querying Customer models. To include a related model you would use the include filter { filter: { include: ['orders'] } }. I need to do some…
Berkeley Martinez
  • 2,786
  • 2
  • 14
  • 18
1
vote
1 answer

How to use Loopback ACL modify permissions on the user role

I am trying to understand the loopback acl but failed, if I can use loopback acl control role authorization, what should I do? When I get request GET http://localhost:1337/api/Employees 401 (Unauthorized) { "error": { "name": "Error", …
dblose
  • 23
  • 1
  • 8
1
vote
3 answers

Error: The middleware loopback.favicon is not installed

I am new to loopback, I setup a new loopback application, and run npm install and after doing node server/server.js I am getting the below mentioned error, I tried googling it, but was of no use,,, Error: The middleware loopback.favicon is not…
Nishant
  • 3,614
  • 1
  • 20
  • 26
1
vote
1 answer

How to hide REST API methods in LoopBack 2.0?

I haven't managed to hide API methods in LoopBack 2.0. According to the documentation, I should achieve this with something like: var app = require('../app'); var Location = app.models.Location; Location.deleteById.shared = false; Howver, this…
kYuZz
  • 1,572
  • 4
  • 14
  • 25
1
vote
1 answer

Full-duplex messaging between remote autonomous Node.js applications over WebSockets?

There will be no human being in the loop, and both endpoints are autonomous Node.js applications operating as independent services. Endpoint A is responsible for contacting Endpoint B via secure web socket, and maintaining that connection…
Chris
  • 824
  • 1
  • 7
  • 26
1
vote
1 answer

How to Call Method of ModelB.js from within ModelA.js?

I am working with loopback 2.0. I generated my models with the yeoman generator and added a js file for each model to extend its behavior. How can I call a method from ModelA within ModelB? EXAMPLE Folder structure: /common /models Car.json …
electronix384128
  • 6,625
  • 11
  • 45
  • 67
1
vote
4 answers

Iterate through Array, update/create Objects asynchronously, when everything is done call callback

I have a problem, but I have no idea how would one go around this. I'm using loopback, but I think I would've face the same problem in mongodb sooner or later. Let me explain what am I doing: I fetch entries from another REST services, then I…
ewooycom
  • 2,651
  • 5
  • 30
  • 52
1
vote
1 answer

mongodb belongsTo Foreign key is null

So this question feels a lot like my last one. Strongloop is making me feel like such a noob. lol. I stole this from some of the LB examples: var Order = mongoDev.createModel('order', { customerId: Number, orderDesc: String }); var Customer…
huxley
  • 295
  • 1
  • 3
  • 13
1
vote
2 answers

strongloop loopback send email

I see that loopback comes with nodemailer integrated as a node module. I tried to follow the docs to send a hello world mail via the angular-sdk http://apidocs.strongloop.com/loopback/#emailsendoptions-callback However, the docs are not really…
enigma
  • 79
  • 2
  • 11
1
vote
1 answer

loopback postgresql fetches "id" field only

I try to make a project with using of loopback and remote postgresql database. Tables are filled and I see it in pgAdmin. I have this code: /models/language.js var loopback = require('loopback'), app =…
zaycker
  • 37
  • 5