
Security News
Node.js TSC Declines to Endorse Feature Bounty Program
The Node.js TSC opted not to endorse a feature bounty program, citing concerns about incentives, governance, and project neutrality.
github.com/cognifly/go-mwclient
go-mwclient is a library for interacting with the MediaWiki API. The package's actual name is "mwclient", but it is called "go-mwclient" to avoid confusion with similarly named libraries using other languages.
The canonical import path for this package is
import cgt.name/pkg/go-mwclient // imports "mwclient"
Documentation:
go get cgt.name/pkg/go-mwclient
go-mwclient's API seems to have stabilized. It probably won't change significantly, if at all.
package main
import (
"fmt"
"cgt.name/pkg/go-mwclient"
"cgt.name/pkg/go-mwclient/params"
)
func main() {
// Make a Client object and specify the wiki's API URL and your user agent.
w, err := mwclient.New("https://en.wikipedia.org/w/api.php", "Username's wikibot")
if err != nil {
panic(err)
}
// Log in.
err = w.Login("USERNAME", "PASSWORD")
if err != nil {
fmt.Println(err)
}
// Specify parameters to send.
parameters := params.Values{
"action": "query",
"list": "recentchanges",
"rclimit": "2",
"rctype": "edit",
"continue": "",
}
// Make the request.
resp, err := w.Get(parameters)
if err != nil {
fmt.Println(err)
}
// Print the *jason.Object
fmt.Println(resp)
}
To the extent possible under law, the author(s) have dedicated all copyright and related and neighboring rights to this software to the public domain worldwide. This software is distributed without any warranty.
You should have received a copy of the CC0 Public Domain Dedication along with this software. If not, see http://creativecommons.org/publicdomain/zero/1.0/.
FAQs
Unknown package
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The Node.js TSC opted not to endorse a feature bounty program, citing concerns about incentives, governance, and project neutrality.
Research
Security News
A look at the top trends in how threat actors are weaponizing open source packages to deliver malware and persist across the software supply chain.
Security News
ESLint now supports HTML linting with 48 new rules, expanding its language plugin system to cover more of the modern web development stack.