@urban-zoo/spread-the-word
v0.0.11
Published
spread-the-word
Downloads
10
Readme
spread-the-word
dev
# twitter:
export CONSUMER_KEY=""
export CONSUMER_SECRET=""
export ACCESS_TOKEN=""
export ACCESS_TOKEN_SECRET=""
export TWITTER_USERNAME=""
# linkedin access token
export LINKEDIN=""
export LINKEDIN_ID=""
# instagram
export INSTA_USERNAME=""
export INSTA_PASSWORD=""
# blogs
export BLOG_MEDIUM=""
export BLOG_DEVTO=""
export BLOG_HASHNODE=""
export BLOG_HASHNODE_USERNAME=""
usage
simple example:
async function main() {
const shareController = new ShareController({
entries: {
path: [__dirname],
file: 'entries',
},
store: {
path: [__dirname],
file: 'store',
},
markdownPath: `${__dirname}/markdown`,
imgPath: `${__dirname}/img`,
})
await shareController.shareScheduled()
}
main()
instagram example:
[
{
"targets": "instagram",
"ts": "2021-12-02",
"content": {
"entries": ["Trees of Life", "#nft #opensea"],
"image": {
"path": "0.jpg",
"alt": "Trees of Life"
},
"url": {
"url": "https://opensea.io/",
"title": "Trees of Life"
}
}
}
]
get credentials
- linkedin: https://www.linkedin.com/developers/tools/oauth/token-generator
- twitter: https://developer.twitter.com/
roadmap
- add instagram: https://www.npmjs.com/package/instagram-private-api