<commit_before>import { Injectable } from '@angular/core';
import {Http, Headers} from '@angular/http';
import 'rxjs/add/operator/map';
import { Observable } from 'rxjs';

@Injectable()
export class FTCDatabase {

  year = 1617;

  constructor(private http: Http) {}

  private request(url: string) {
    const auth_header = new Headers({
      'X-Application-Origin': 'TOA'
    });
    return this.http.get('http://theorangealliance.org:8009/apiv2' + url, { headers: auth_header });
  }

  public getAnnouncements() {
    return this.request('/web/announcements').map(res => res.json());
  }

  public getWebChangelog() {
    return this.request('/web/changelog').map(res => res.json());
  }

  public getAPIDoc() {
    return this.request('/web/doc').map(res => res.json());
  }

  public getAllSeasons() {<commit_msg>API routing changes for v2.<commit_after>import { Injectable } from '@angular/core';
import {Http, Headers} from '@angular/http';
import 'rxjs/add/operator/map';
import { Observable } from 'rxjs';

@Injectable()
export class FTCDatabase {

  year = 1617;

  constructor(private http: Http) {}

  private request(url: string) {
    const auth_header = new Headers({
      'X-Application-Origin': 'TOA'
    });
    return this.http.get('http://theorangealliance.org:8080/apiv2' + url, { headers: auth_header });
  }

  public getAnnouncements() {
    return this.request('/web/announcements').map(res => res.json());
  }

  public getWebChangelog() {
    return this.request('/web/changelog').map(res => res.json());
  }

  public getAPIDoc() {
    return this.request('/web/doc').map(res => res.json());
  }

  public getAllSeasons() {
{'fraction_non_alphanumeric': 0.1686819830713422, 'fraction_numerical': 0.011487303506650543, 'mean_word_length': 3.896449704142012, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6181125', 'n_tokens_mistral': 571, 'n_tokens_neox': 544, 'n_words': 114}