Creating a Service

In this lesson, we'll create a service to make a request to the Enzoic API.

We'll cover the following

The validator we’re creating will need to make a request to the Enzoic API. The API is expecting the password hash data. We’ll talk about hashes when we need to send the password.

First things first, we need to create a service. We have the option of performing the request in the validator. However, we should outsource the request in a service for reusability. It also allows us to practice writing services and to work with observables.

Here’s how the flow of data will look like:

Get hands-on with 1200+ tech skills courses.