Receita

Listar receitas

curl "$AMBIENTE/rpc/v1/finance.get-revenue" \
-H "Authorization-Compufacil: $TOKEN"

Criar receita

curl "$AMBIENTE/rpc/v1/finance.post-revenue" \
-H "Authorization-Compufacil: $TOKEN" \
-H "Content-Type: application/json" \
--data '
{
    "description": "teste teste",
    "value": 666
}
'
$ {"id":152611}
export REVENUE_ID=152611

Pegar um receita detalhada

curl "$AMBIENTE/rpc/v1/finance.get-revenue" \
-H "Content-Type: application/json" \
-H "Authorization-Compufacil: $TOKEN" -d '{"id": '$REVENUE_ID'}'

Atualizar uma receita

curl "$AMBIENTE/rpc/v1/finance.put-revenue\
-H "Authorization-Compufacil: $TOKEN" \
-H "Content-Type: application/json"
--data '
{
    "description": "teste teste",
    "value": 666,
    "id": $REVENUE_ID
}'

$ {"id":152611}

Excluir receita

curl "$AMBIENTE/rpc/v1/finance.delete-revenue"  \
-H "Authorization-Compufacil: $TOKEN" \
-H "Content-Type: application/json" \
--data '{"id": $REVENUE_ID}'
$ {"id":152611}