mailmeteor 0.0.12 → 0.0.14
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.
- package/dist/index.cjs +8 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +6 -0
- package/dist/index.mjs +8 -1
- package/dist/index.mjs.map +1 -1
- package/dist/types/index.d.ts +6 -0
- package/dist/types/index.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -2754,8 +2754,14 @@ declare class Mailmeteor {
|
|
|
2754
2754
|
constructor(key: string, config?: MailmeteorConfig);
|
|
2755
2755
|
/**
|
|
2756
2756
|
* Update the API key for authentication
|
|
2757
|
+
* @param key - The new API key to use for authentication.
|
|
2757
2758
|
*/
|
|
2758
2759
|
setApiKey(key: string): void;
|
|
2760
|
+
/**
|
|
2761
|
+
* Update the base URL for the API. Useful for testing and debugging.
|
|
2762
|
+
* @param baseUrl - The new base URL to use for API requests.
|
|
2763
|
+
*/
|
|
2764
|
+
setApiBaseUrl(baseUrl: string): void;
|
|
2759
2765
|
}
|
|
2760
2766
|
|
|
2761
2767
|
export { Mailmeteor, types_gen_d as MailmeteorTypes };
|
package/dist/index.mjs
CHANGED
|
@@ -1625,7 +1625,7 @@ function querySerializer(query) {
|
|
|
1625
1625
|
}
|
|
1626
1626
|
class Mailmeteor {
|
|
1627
1627
|
constructor(key, config) {
|
|
1628
|
-
const baseUrl = config?.baseUrl ||
|
|
1628
|
+
const baseUrl = config?.baseUrl || 'https://api.mailmeteor.com/v1';
|
|
1629
1629
|
this.client = createClient(createConfig({
|
|
1630
1630
|
baseUrl,
|
|
1631
1631
|
throwOnError: true,
|
|
@@ -1653,6 +1653,13 @@ class Mailmeteor {
|
|
|
1653
1653
|
},
|
|
1654
1654
|
});
|
|
1655
1655
|
}
|
|
1656
|
+
setApiBaseUrl(baseUrl) {
|
|
1657
|
+
const currentConfig = this.client.getConfig();
|
|
1658
|
+
this.client.setConfig({
|
|
1659
|
+
...currentConfig,
|
|
1660
|
+
baseUrl,
|
|
1661
|
+
});
|
|
1662
|
+
}
|
|
1656
1663
|
}
|
|
1657
1664
|
|
|
1658
1665
|
export { Mailmeteor, types_gen as MailmeteorTypes };
|