commet 1.8.0 → 1.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +4 -11
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -30,7 +30,7 @@ var import_commander12 = require("commander");
30
30
  // package.json
31
31
  var package_default = {
32
32
  name: "commet",
33
- version: "1.8.0",
33
+ version: "1.8.1",
34
34
  description: "Commet CLI - Manage your billing platform from the command line",
35
35
  bin: {
36
36
  commet: "./bin/commet"
@@ -165,13 +165,7 @@ function clearProjectConfig() {
165
165
  }
166
166
 
167
167
  // src/utils/api.ts
168
- var BASE_URL = "https://beta.commet.co";
169
- function bypassHeaders() {
170
- return {
171
- Cookie: "_vercel_jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJiZXRhLmNvbW1ldC5jbyIsImJ5cGFzcyI6IjFERUlTcngyczA3YXFjVmhBbVhDUnhjTEdvOHNZaGFTIiwiaWF0IjoxNzc4NjkxNzMxLCJzdWIiOiJwcm90ZWN0aW9uLWJ5cGFzcy1hdXRvbWF0aW9uIn0.ONjvMguLM-7wXfTppY1cQveu9IN05x4VSblB39YpW_A",
172
- Origin: "https://beta.commet.co"
173
- };
174
- }
168
+ var BASE_URL = "https://commet.co";
175
169
  async function apiRequest(endpoint, options = {}) {
176
170
  const auth = loadAuth();
177
171
  if (!auth) {
@@ -182,7 +176,6 @@ async function apiRequest(endpoint, options = {}) {
182
176
  ...options,
183
177
  headers: {
184
178
  ...options.headers,
185
- ...bypassHeaders(),
186
179
  Authorization: `Bearer ${auth.token}`,
187
180
  "Content-Type": "application/json"
188
181
  }
@@ -232,7 +225,7 @@ async function performLogin() {
232
225
  try {
233
226
  const deviceResponse = await fetch(`${BASE_URL}/api/auth/device/code`, {
234
227
  method: "POST",
235
- headers: { "Content-Type": "application/json", ...bypassHeaders() },
228
+ headers: { "Content-Type": "application/json" },
236
229
  body: JSON.stringify({
237
230
  client_id: "commet-cli",
238
231
  scope: "openid profile email"
@@ -271,7 +264,7 @@ async function performLogin() {
271
264
  try {
272
265
  const tokenResponse = await fetch(`${BASE_URL}/api/auth/device/token`, {
273
266
  method: "POST",
274
- headers: { "Content-Type": "application/json", ...bypassHeaders() },
267
+ headers: { "Content-Type": "application/json" },
275
268
  body: JSON.stringify({
276
269
  grant_type: "urn:ietf:params:oauth:grant-type:device_code",
277
270
  device_code,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "commet",
3
- "version": "1.8.0",
3
+ "version": "1.8.1",
4
4
  "description": "Commet CLI - Manage your billing platform from the command line",
5
5
  "bin": {
6
6
  "commet": "./bin/commet"