Giter VIP home page Giter VIP logo

kickcore's Introduction

KickCore

Is a football API Server (language: Persian)

Copyright - Changelog


How It Works?

             |      |---------|                     |---------|
Request ---> | ---> |         | --- Not Exists ---> |   API   |
             |      |         |                     |---------|
             |      |  Cache  |                          |
             |      |         |                        Result
             |      |         | <------------------------|
             |      |---------|                          |
             |           |                               |
             |         Exists                            |
             |           |                               |
             |  <--------|-------------------------------|

Install

Build From Source

Requirements

  • Go (version 1.7 or above)
go install github.com/awolverp/kickcore@latest

API

KickCore API Documentation.

Note: {url} is the host that kickcore uses e.g. 'http://127.0.0.1:9090'

Search

Search.

curl "{url}/api/search"

Query Params

Key Value Description
q string Search Query (q length must be > 4).

Adavnced Search

Search (you can filter result).

curl "{url}/api/search/advanced"

Query Params

Key Value Description
q string Search Query (q length must be > 4).
filter integer Filter result. zero means teams, 1 means players, 2 means coaches, 3 means competitions
limit integer Optional. Result limit
offset integer Optional. Result offset

List of competitions

Get list of competitions which are supported.

curl "{url}/api/competitions-list"

Weeks of competition

Get weeks of a competition.

curl "{url}/api/competition/weeks"

Query Params

Key Value Description
id string Current ID of the competition

Competition Standing Table

Get standing table of a competition.

curl "{url}/api/competition/standing-table"

Query Params

Key Value Description
id string Current ID of the competition

Competition Matches by week

Get standing table of a competition.

curl "{url}/api/competition/matches/week"

Query Params

Key Value Description
id string Current ID of the competition
n integer Week number

Match info

Get match information.

curl "{url}/api/match/info"

Query Params

Key Value Description
id string Match ID

Matches

Get matches by date.

curl "{url}/api/matches"

Query Params

Key Value Description
days integer Optional. Zero is today. 1 is tomorrow, 2 two days later, etc. (and you can pass nagative numbers).

Transfers Regions

Get regions (and seasons) which have transfers.

curl "{url}/api/transfers/regions"

Transfers

Get transfers of a season.

curl "{url}/api/transfers"

Query Params

Key Value Description
sid string seasion ID

Memory Stats (Developer API)

Get memory usage/stats of script.

curl "{url}/stats/mem"

Query Params

Key Value Description
unit string Optional. Is the unit byte (b or byte, kb or kilobyte, mb or megabyte). default is byte.

Questions

How to write expire ttl file?

What is extra_ttl.json file?

You can specify the expiration time (TTL) of each api with expire ttl file.

How to write? Each api has key that you can use it to specify expiration time.

Keys

  • Advanced Search: ADVANCED_SEARCH
  • Competition Standing Table: COMPETITION_STANDING_TABLE
  • Competition Weeks: COMEPTITION_WEEKS
  • List of competitions: COMPETITIONS_LIST
  • Match info: MATCH_INFO
  • Matches: MATCHES_BY_DATE
  • Competitions match by week: MATCHES_BY_WEEKNUMBER
  • Transfers: TRANSFERS
  • Transfers Regions: TRANSFERS_REGIONS

Other keys will ignored

What value can be set? Integer (means seconds) or string (duration, see extra_ttl.json file for examples)

kickcore's People

Contributors

awolverp avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.