mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 10:56:53 +00:00
🤖 Merge PR #44723 @types/dogapi Add optional api_host by @omakoleg
* Add optional api_host
Use case:
```
dogapi.initialize({
api_host: 'api.datadoghq.eu',
api_key,
app_key
})
```
* Modify tests
This commit is contained in:
parent
8f662ae62d
commit
f3bf99433b
@ -5,10 +5,15 @@ dogapi.initialize({
|
||||
app_key: '',
|
||||
});
|
||||
|
||||
dogapi.initialize({
|
||||
api_host: 'a',
|
||||
api_key: 'b',
|
||||
app_key: 'c',
|
||||
});
|
||||
dogapi.event.create('', '', (err: Error | null, res: dogapi.EventCreateResponse) => {});
|
||||
dogapi.event.create(
|
||||
'',
|
||||
'',
|
||||
{ date_happened: Math.floor(Date.now() / 1000) },
|
||||
(err: Error | null, res: dogapi.EventCreateResponse) => {}
|
||||
(err: Error | null, res: dogapi.EventCreateResponse) => {},
|
||||
);
|
||||
|
||||
1
types/dogapi/index.d.ts
vendored
1
types/dogapi/index.d.ts
vendored
@ -7,6 +7,7 @@
|
||||
export function initialize(opts: {
|
||||
api_key: string,
|
||||
app_key: string,
|
||||
api_host?: string
|
||||
}): void;
|
||||
|
||||
interface event {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user