File size: 414 Bytes
3d979b2
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
/**
 * Line API client
 */
class Line {
  /**
   * Get data from Line API
   * @return {object} Data from Line API
   */
  static getData() {
    var options = {
      "method": "GET",
      "headers": {
        "Authorization": "Bearer " + CONFIG.LINE_ACCESS_TOKEN
      }
    };
    var response = UrlFetch.fetch("https://api.line.me/v2/profile", options);
    return JSON.parse(response.getContentText());
  }
}