mirror of
https://github.com/balzack/databag.git
synced 2025-02-16 05:29:15 +00:00
10 lines
332 B
JavaScript
10 lines
332 B
JavaScript
import { checkResponse, fetchWithTimeout } from './fetchUtil';
|
|
|
|
export async function getCardDetail(server, token, cardId) {
|
|
let param = "?agent=" + token
|
|
let detail = await fetchWithTimeout(`https://${server}/contact/cards/${cardId}/detail${param}`, { method: 'GET' });
|
|
checkResponse(detail);
|
|
return await detail.json()
|
|
}
|
|
|