UpdateMYRATE.go
in the package /internal/pkg/ratescrapers
. The central method is UpdateMYRATE()
. This method acts on a RateScraper struct which is defined in RateScraper.go in the ratescrapers package. For instance, for the the Euro Short-Term Rate (ESTER) issued by the ECB, UpdateESTER.go
would look likeexchange-scrapers/
and call it MySourceScraper.go
. The main difference between scrapers is the Update()
method, where the actual scraping is done.RateScraper
from the ratescrapers
package is something like this:InterestRate
from pkg/model/types.go
chanInterestRate
of s
. In order to write a new scraper, it is not imperative to understand the architecture of the pathway from top to bottom, but it might be helpful. For a first impression you can have a look at the following diagram.