GithubHelp home page GithubHelp logo

vk-parser-service's Introduction

Vk Parser Service.

Description.

UNDER CONSTRUCTION.

List of endpoints.

1. POST /getProfiles

TORUN.

  • go get github.com/mrKitikat/Vk-Parser-Service.

  • cd $GOPATH/src/github.com/mrkitikat/vk-parser-service/src

  • dep ensure.

  • go run main.go

Config file.

Config in config.json.

{
	"name": "Vk Parser Service",
	"vk": {
		"url": "https://api.vk.com/method/",
		"version": "",
		"token": ""
	},
	"server": {
		"host": "",
		"port": ""
	}
}

Default:

  • vk.version --- Version of vk api. Type: String. Default: "5.103".
  • vk.token --- Your private api token. Type: String.
  • server.host --- Host of Vk Parser Service. Type: String. Default: "localhost".
  • server.port --- Port of Vk Parser Service. Type String. Default: "8080".

1. POST /getProfiles

Description.

UNDER CONSTRUCTION.

Request.

  • "Content-Type", "application/json"

  • POST http://service.host:service.port/getProfiles

Body:

{
	"id": string // User id
	"intersect_number": int //current minimum number(N) of occurrences, N > 1
	"sex": int // 1 - woman, 2 - man
	"Message": bool // can write private message
}

Responce .

1. StatusCode = 200:

Body:

{
	"text": "",
	"responce": 
}

Cases.

    • "text": "The list is empty". Means that intersection is empty with current params from request.
    • "responce": ""
    • "text": "We found N people". Means that intersection is not empty and contains N people with current params from request.
    • "responce": [id_1, id_2, ..., id_N]. Contains people's id from intersection. Type []int64.

Examples.

Returned group members with ids: [1, 2, 4, 6, 1, 3, 1, 2, 3].

  • IF intersect_number = 2 in request ---> intersection is [1, 2, 3].
  • ELSE IF intersect_number = 3 in request ---> intersection is [1].
  • ELSE IF intersect_number = 4 in request ---> intersection is [ ].

Other parameters from the request impose additional constraints.

TODO

  • Parsing members.
  • Intersection groups.
  • Tests for intersection methods.
  • Parse posts.
  • Tests for posts methods.
  • Parse comments.
  • Tests for comments methods.
  • Parse what user likes.
  • Tests for like methods.

vk-parser-service's People

Contributors

mellaught avatar chillhacker avatar

Watchers

James Cloos 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.