We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Expected: https://github.com/twilio/twilio-node?tab=readme-ov-file#enable-debug-logging Observed: HTTP requests are not logged using the latest release of twilio for node
twilio
Pass logLevel from the twilio client instance to the http request instance
logLevel
n/a
No response
The text was updated successfully, but these errors were encountered:
Here is a simple repro:
import twilio from "twilio"; const accountSid = process.env.TWILIO_ACCOUNT_SID || ''; const authToken = process.env.TWILIO_AUTH_TOKEN || ''; if (!accountSid || !authToken) { throw new Error('Twilio credentials are missing. Set TWILIO_ACCOUNT_SID and TWILIO_AUTH_TOKEN in your environment.'); } export const twilioClient = twilio(accountSid, authToken, { logLevel: 'debug', }); async function listUsageRecord() { console.log(twilioClient.logLevel); // prints `debug` const records = await twilioClient.usage.records.daily.list({ category: "sms-outbound", limit: 100, pageSize: 100 }); } listUsageRecord().catch(console.error)
Simply debug is printed as opposed to expected HTTP calls.
debug
Sorry, something went wrong.
No branches or pull requests
Preflight Checklist
Problem Description
Expected: https://github.com/twilio/twilio-node?tab=readme-ov-file#enable-debug-logging
Observed: HTTP requests are not logged using the latest release of
twilio
for nodeProposed Solution
Pass
logLevel
from the twilio client instance to the http request instanceAlternatives Considered
n/a
Additional Information
No response
The text was updated successfully, but these errors were encountered: