I want To create Anew API To Use It on app i have web site and want to make API for it, where i should create an API in Frontend Or Backend OR create anew module same frontend level ???
and How I can Create A Module in Yii2 ??
In my opinion you should create a separate module for API.
Please follow below link to learn how to create module.
How to create Modules in Yii2
And for RESTful Web Services follow :
RestApi with yii2
Related
like the title says, I want to extend the VC platform API endpoints with the built in API Authentication (via the API key).
I followed the tutorial to create a managed module, and I can successfully make the API calls. However, it doesn't include any authentication. I am wondering how would I accomplish this?
Another question is that in order to have the VC Storefront to use my custom API endpoints, I would have to generate the module API using the AutoRest on the VC Storefront project, correct?
Thnak you all in advance!
VC uses platform API with APIRequestHandler, that uses ApppId and SecretKey to add header to every API request:
request.Headers.Authorization = new AuthenticationHeaderValue("HMACSHA256", signature.ToString());
Then handler is used by every endpoint - link to code.
More info on authentication could be found here:
Working with platform API.
Another question is that in order to have the VC Storefront to use my custom API endpoints, I would have to generate the module API using the AutoRest on the VC Storefront project, correct?
Yes, correct.
I have SPA app with backend REST API (Symfony) with JWT authentication and necessary methods to communicate with my frontend app (Angular). And now i want to add another service ( Magento ) to comunicate with my backend.
Should Magento use same methods including authentication or its better to create separate module in my Symfony app with it's own methods?
You should reuse what is possible and makes sense, and only create separate API resources for new functionality. There is no point to create duplicate logic, unless there are differences between the use of the two consumers.
We currently have an Ember app that's able to process GitHub repositories. Is it possible to create an API using Ember based from the current Ember app?
No. Ember is client side framework only, you can't create API using it
I have created one application in mulesoft, I'm trying to create an api for that application in api manager, can anyone provide the steps for integrating both?
You can follow the steps given in this doc, use your application endpoint as backend while creating the API
https://docs.wso2.com/display/AM200/Create+and+Publish+an+API
Have a running Yii1 application. How to enhance Yii1 application with Yii2 restfull api instead of rewriting the whole Yii1 application in Yii 2?
You can work with two separate application or with a yii2 and yii1 application integrated . see this doc for details.
Essentially you must install Yii 2 in your existing application and modify the entry script of the application as indicated in the doc ,
Because both Yii 1 and Yii 2 have the Yii class, you should create a customized version to combine them.
Once you have your yii2 application you can call the services you need
here you can find a quick start guide for restful webservices in yii2