This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 🌞 Morning 120 commits ██▊░░░░░░░░░░░░░░░░░░ 13.2% | |
| 🌆 Daytime 380 commits ████████▊░░░░░░░░░░░░ 41.8% | |
| 🌃 Evening 221 commits █████░░░░░░░░░░░░░░░░ 24.3% | |
| 🌙 Night 189 commits ████▎░░░░░░░░░░░░░░░░ 20.8% |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| app.post('/send', async (req, res) => { | |
| const { from, to, text } = req.body | |
| const { APP_COOKIE } = req.cookies | |
| const result = await request({ | |
| method: 'POST', | |
| uri: 'https://api.solapi.net/messages/v4/send', | |
| headers: { | |
| 'Authorization': `bearer ${APP_COOKIE}` | |
| }, | |
| body: { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const bodyParser = require('body-parser') | |
| app.use(bodyParser.urlencoded({ | |
| extended: true | |
| })) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <html> | |
| <head> | |
| <title>문자 발송</title> | |
| </head> | |
| <body> | |
| <form action="/send" method="post"> | |
| <input type="text" placeholder="발신번호" name="from"> | |
| <input type="text" placeholder="수신번호" name="to"> | |
| <input type="text" placeholder="내용" name="text"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| app.get('/send', (req, res) => { | |
| res.render('send') | |
| }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| res.redirect('send') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| res.cookie('APP_COOKIE', result.access_token, { | |
| 'httpOnly': false, | |
| 'signed': false, | |
| 'encode': String | |
| }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const cookieParser = require('cookie-parser') | |
| app.use(cookieParser()) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "access_token": "eyGciOiNiIsIkpXVCJ9.eyJ0NTY3ODkwIiwibWRtaW4iOnRydWV9...", | |
| "refresh_token": "ciOiJIUzI1NkpXVCJ9.dWIiOiIxMjM0Y3ODIiwibmFtZSIkpv4gR...", | |
| "scope": [ "message:write" ], | |
| "token_type": "Bearer" | |
| } |
NewerOlder