Many web services use some kind of authentication method to secure access to the web service. There are a lot of authentication types available, one of which is Basic Authentication. In this How-To we will guide you through the process of setting up Basic Authentication for your Web Service. 


Prerequisites


  • A web service that requires Basic Authentication;


How To


  1. Go to https://design.appmachine.com and login;
  2. Select an existing app or create a new app;
  3. Click the "Add block" button;
  4. Select the "Pro" tab;
  5. Select the "Web Service" block and click "Add Block";
  6. Click "Custom Web Service";
  7. Enter the URL of your Web Service;
  8. Now you need to specify the Basic Authentication. AppMachine uses (so called) Authorization Providers to specify any type of authentication that should be used during a Web Service call. So to setup Basic Authentication we need to create a Basic Authentication Authorization Provider. To do so, click the "+" button next to the Authorization provider field.
  9. A wizard will open. This wizard will allow you to create a new Authorization Provider. First you will need to switch the Type to Basic;
  10. You will see that the number of fields you will have to fill out will be reduced to just Three;
  11. First we will give the Authorization Provider a recognizable name;
  12. Next, enter the Username and Password;
  13. By enabling the option "Use my credentials in the app" the Web Service will always use the username and password you provided. Otherwise the user will be prompted to enter their username and password.
  14. Click "Finish";
  15. Select the Authorization Provider you've just created;
  16. Click "Go";
  17. We will perform a test call using the specified credentials, and when successful you can finish the Web Service integration;