Angulars RESTful calls

heeey for everyone :smiley: i hope that are u goood so guys i’m using angularJS1 with ionic to develep a mobile app this app should communicates with a RESTful API created with J2EE actually i don’t have backend or any rest api in server side all what i have is client side so i have two questions guys

  1. did angularjs provide some API to communicate with RESTful api ??
  2. can i use postman chrome extension to test my angularjs rest calls ?? if yes how give some tutorial links .
    thank u very much for sharing your khnowledge that’s amazing from amazing people ;D

You can use the core service from Angular called $http. I’m currently using it in my own project without issues.

I don’t understand what you mean when you say that you don’t have a backend or api on server side, but to if you have an URI to the service in any way, it should universally be quite simple to access the rest service you’re aiming for.

Using Postman to access a rest-service is very straight forward as long as you know the resource URI:

Hope it helps!

good brother :smiley: after some googling i found thath there are tree ways $http ,$resource or restangular in fact i don’t know which is better and more useful that 's from first part of my question
when i saaid that i don’t have a backend or api on server side i mean that i don’t have URI of any service i had already prepared my angularjs calls exemple for get method and other for post method which put some JSON data in body of http problem is how can i test that work with postman and i don’t have URI where to send request i hope u’ll understand what i mean :smiley:

Well, you could always try this base if you wanna try out get-requests through rest:
http://northwind.servicestack.net/

Other than that, I’m sure there are some demo-services somewhere you can google to find an example for patching as well.
By the looks of it, OData provides a demo read-write database, but I haven’t tried it out for myself:
http://www.odata.org/blog/odata-v3-demo-services/

so i understand that postman is not useful in my case ?

Postman is useful if you want to inspect a Rest-URI, so you can try out the northwind-URI with postman and see if it serves you the same result as you get in your app, for instance

thank you brother :smiley: