build
This commit is contained in:
parent
1d2ac18171
commit
0172055539
15 changed files with 44 additions and 41 deletions
|
|
@ -1,17 +0,0 @@
|
|||
import node_fetch from "cross-fetch";
|
||||
import { respostaComuns } from "p-respostas";
|
||||
import { urlAutenticacao } from "./_urlAutenticacao";
|
||||
export const usuarios_quipo_governo = async ({ token_produto, ambiente, }) => {
|
||||
const url = `${urlAutenticacao(ambiente)}/api/usuarios_quipo_governo`;
|
||||
if (!token_produto)
|
||||
return respostaComuns.erro("token_produto não informado");
|
||||
const headers = {
|
||||
token: token_produto,
|
||||
};
|
||||
return node_fetch(url, {
|
||||
headers,
|
||||
})
|
||||
.then((r) => r.json())
|
||||
.catch((e) => respostaComuns.erro(`Erro ao buscar usuários quipo governo ${e.message}`))
|
||||
.then((r) => r);
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue