@bunpmjs/cloudflareapi
0.0.2 • Public • Published cloudflareapi
ENV (env variables)
- CLOUDFLARE_TOKEN=
Make sure your api token is set to perform the requests to the account to the endpoint
Usage
Initialization
// the token can be set in the .env or in the constructor
const cfApi = new cloudflare({
token: "<Token>"
});
DNSrecords management
cfApi.DNSRecords.update({
zone_id: "<zone_id>",
set: {
current_name: "<current_record_name>",
name: "<new_name || current_record_name>",
proxied: true | false,
type: "record type"
}
})
Readme
Keywords
nonePackage Sidebar
Install
npm i @bunpmjs/cloudflareapi
Weekly Downloads