# Ask Dri for the invoice (DANFE and XML) and the order copy

> Ask Dri for the invoice number and key, the DANFE as PDF, the XML and the order copy as PDF, right in the conversation.

Source: https://vendria.com/en/ajuda/nota-fiscal-e-copia-do-pedido-pela-dri

## What you can ask for

In the conversation with Dri (WhatsApp, Telegram or the chat) you can ask for an order's
invoice number, the access key, the DANFE as PDF, the authorized XML,
the list of the latest invoices and the order copy as PDF. It works for those who sell and
for those who administer, each on the orders they can look up, the same rule
as for status:

- **seller**: the orders of the customers in your portfolio;
- **store administrator**: the orders of all customers of the stores you
  administer;
- **Company owner and administrator**: the orders of all stores of the
  company.

See [Ask for an order's status on WhatsApp](/en/ajuda/status-do-pedido-pelo-whatsapp).

Dri does not issue invoices. She shows and delivers what the store's ERP has already
issued.

## The invoice number and key

Ask *"what's the invoice for order 412?"* and the reply brings the invoice with number,
series, issue date and amount. If the invoice was canceled, the word CANCELED comes
right after the number, before the amount.

The access key comes when you ask for it: *"send me the invoice key for
order 412"*. Once the invoice has already appeared in the conversation, *"send me the key
for that invoice"* is enough, without repeating the number. The key comes in blocks of four digits, to
check with the customer, and, when the invoice is valid, with the link to look it up at
SEFAZ. A canceled invoice does not get that link. If the ERP did not record the key, she
says so: *"access key: not recorded for this invoice"*.

When the order has no invoice yet, the reply says why:

- *"This order hasn't been invoiced yet: no invoice has been issued."*;
- *"There's no invoice yet: this order hasn't reached the ERP yet."*;
- *"There's no invoice yet: this order hasn't been sent to the ERP yet."*

To find out whether the invoice is authorized or canceled, ask just like that:
*"is the invoice for order 412 authorized?"*. When the store has the ERP's tax
document database connected to Vendria, she checks the invoice document.
When it does not, she warns you: *"I can't check the invoice's authorization
from here"*, and the status shown is what the ERP recorded.

## The DANFE as PDF

Ask by naming the file and the DANFE comes attached: *"send me the DANFE for order
412"* or *"send me the invoice pdf for 412"*. The reply brings the invoice data and
*"Here's the invoice file."*, with the PDF attached.

If you only ask *"send me the invoice for order 412"*, without saying which file,
Dri brings the invoice data (with the key) and asks: *"Would you like me to send you
the DANFE as PDF?"*. Reply *"yes"* and the file arrives with *"Here's the DANFE as
PDF."*; reply *"no"* and she stops there. She only asks this when the
DANFE exists.

Dri fetches the file from the store's ERP at the moment you ask. Nobody needs to
open the order screen first. When the invoice is canceled, the DANFE is sent
anyway, with the warning *"⚠️ Attention: this invoice is CANCELED."* or with the word
CANCELED on the invoice line.

## The XML

The XML is not sent as an attachment: you get a link that opens the authorized XML on the website, without
signing in. Dri's sentence is *"I can't send the XML as an attachment here. The authorized
XML opens directly on the website, without signing in:"*, followed by the link. Ask with the
word XML: *"send me the xml of the invoice for order 412"*.

When the link cannot be generated, she says where the file is: *"The authorized
XML is on the website, on the order's ERP page."* The invoice files that
exist appear on the quote, in the ERP order section. See [The order as it ended up in the ERP](/en/ajuda/o-pedido-no-erp).

## When the file does not come

There are two different replies, and each one calls for something different.

- *"I didn't find its PDF (DANFE) or XML among the documents the customer's
  ERP delivers to Vendria"*: the file is not among what the connection to the
  store's ERP delivers. This happens with older invoices and with stores whose ERP does not
  send the files. The invoice exists: the number, the key and the SEFAZ lookup
  still hold, but the public lookup does not deliver the document. After
  a search that found nothing, Dri only asks the ERP about that order again
  after 24 hours, so repeating the request right away brings the same
  reply.
- *"I couldn't check the customer's ERP right now. Ask me again in a
  little while."*: the ERP did not respond in time. No search happened here, and it is worth repeating the
  request later.

If you replied *"yes"* to the DANFE offer and the PDF did not come out, she says *"I couldn't
generate the invoice PDF right now."* and reminds you that the identification and the key
are in the previous message.

## Search by the invoice instead of the order

You can also find the order by the invoice number: *"is invoice 654321/2
authorized?"* (number and series), *"invoice 654321"* or the 44 digits of the access
key. The word invoice, NF or DANFE next to the number says it is an invoice number.

*"The invoice for order 123456"* is something else: it is the invoice OF order 123456. When a
bare number could be either an order or an invoice, and both exist, Dri
asks which one you meant.

She looks for the invoice in Vendria's orders and, when the store's integration can
search invoices, also in the ERP. That way she finds the invoice for an order typed directly in the ERP,
as long as the customer is in your portfolio. If there is no invoice with that number and
it belongs to an ERP order, she says so and brings the order: *"I didn't find an invoice with
number 123456, but I found order … from the ERP."*

## The latest invoices

Ask *"latest invoices"*, *"today's invoices"*, *"September
invoices"* or *"invoices for customer X"* and Dri lists the most recent invoices: 10 by
default, and up to 30 if you say how many (*"the last 20 invoices"*). Each line
has the number and series, the status when the invoice was canceled, the issue date,
the customer, the amount and the order: its number in the ERP (*1/123456*) and, when the
order went through Vendria, also the number here. When you serve more than
one store, each line ends with the name of the invoice's store (*· Loja Centro*).

In a store with the newest version of the integration, the list comes from the ERP and includes the
invoices for orders typed directly there. In a store with an older integration,
only the invoices for orders that are in Vendria are included, and the reply warns:
*"For this store, I only listed the invoices for orders that are in Vendria."* If none
of your stores has the new version, the warning is *"This includes the invoices for orders
that are in Vendria; orders typed directly in the ERP are left out."* To get
the DANFE for one of them, ask by number, for example *"send me the DANFE for invoice
654321/2"*.

When there are more invoices than fit, she says how many were left out and suggests
narrowing by period, by customer or, with more than one store, by store (*Loja Centro
invoices*). If no store within your reach has an ERP
that sends invoices to Vendria, she replies *"The invoices from your stores' ERP
don't reach Vendria yet, so I can't list them here."*

The question for the list has to be only about invoices. *"Open invoices for customer
X"*, *"invoice due dates"* or *"open boletos and latest
invoices"* are a different question, about collections, and do not turn into the list.

## The order copy as PDF

Ask *"send me a copy of order ORD-000123"* or *"duplicate of order 412"*
and Dri sends the document's PDF, not the status card. The words that
always work are *copy* and *duplicate*. *"Send me the pdf of order 412"*
also works, but if there is a quote open in the conversation, a PDF request
may be read as that quote's file, or she asks *"Which one do you want the PDF
of?"*. See [Export the quote as Excel or PDF on WhatsApp](/en/ajuda/exportar-cotacao-pelo-whatsapp).

Without a number, as in *"copy of this order"* or *"export as pdf"*, she uses the
document her last reply showed. If the last reply showed more
than one, she asks: *"My last message has more than one document. Which
one do you want a copy of?"*. If the last reply showed no document at all,
she goes with the order you were talking about and, without one, asks *"Which
order do you want a copy of?"*.

In a purchase from several stores, you get one PDF per store, with the list of documents and
each store's name. If a copy cannot be generated, she says which one was left
out and sends the others.

Sending the copy does not change the document, does not export and does not send anything to the ERP: it is
a read. For an order placed directly in the ERP, which did not go through Vendria, the
copy cannot be sent in the conversation: Dri replies *"That order didn't go through
Vendria, so I don't have a copy of it."*

## Adjust the copy in the conversation

After the first copy, ask for the adjustment in words and the PDF comes out again. The
first delivery already suggests: *"If you'd like another format, just ask."* Examples:

- *"remove the order status"*;
- *"send it without the prices"*, the copy for whoever picks the goods;
- *"add the photos"*: product photos start turned off;
- *"change the title to Order mirror"*;
- *"put the items above the invoice"*, to change the order of the sections;
- removing, adding, moving or renaming table columns.

Adjustments add up: *"remove the status"* and then *"remove the invoice too"*
leave both out. *"Bring back the status"* undoes only that adjustment. They only apply
to that conversation and never become the default: the next copy goes back to the
usual template, which is the same for every company.

## What wins over what

Some phrases sound like a copy and are something else:

- *"the invoice pdf"* is the DANFE, not the order copy;
- *"duplicate of the boleto"* is the boleto, not the order copy;
- *"send me the invoice key"* is the key, not the file.

## What she does not do

Dri does not issue invoices, does not cancel invoices and does not send order files
outside your reach. For an order placed directly in the ERP she shows the invoice the ERP
reports and sends the DANFE when you ask for the file by name (*"send me the
DANFE for order 1/123456"*) and the store's ERP delivers the file. The PDF copy
of that order cannot be sent in the conversation.

## Common questions

**Does Dri send the DANFE on WhatsApp?** Yes, when the store's ERP delivers the
file to Vendria. Ask *"send me the DANFE for order 412"* and the PDF comes attached.

**I'm an administrator. Can I ask Dri for an order's invoice?** Yes,
the same way as the seller, and without being tied to a portfolio: you reach
the orders of all customers of the stores you administer.

**Why does the XML come as a link and not as a file?** Because the XML cannot go
as an attachment in the conversation. The link opens the authorized XML on the website, without signing in.

**She said she didn't find the file. Doesn't the invoice exist?** It does: the number, the
key and the SEFAZ lookup confirm it. What did not come was the file, which is not
among the documents the store's ERP delivers to Vendria.

**She said she couldn't check the ERP. What do I do?** Ask again
in a little while. That reply means the ERP did not respond in time, not
that the file does not exist.

**Can I get a copy of the order without the prices?** Yes. Ask for the copy and, right
after, *"send it without the prices"*. The adjustment only applies to that conversation.

**I asked "send me the invoice" and she asked if I wanted the DANFE. Why?** Because
"the invoice" can mean the data or the file. The data already came in the reply; if
you want the PDF, reply *"yes"*.

**Can I see the invoices issued today?** Yes: ask *"today's invoices"*.
With the newest version of the integration, the list comes from the ERP and includes orders
typed directly there. With an older integration, only invoices for orders
that went through Vendria are included.

**Does the order copy change anything on the order or in the ERP?** No. The copy is just
the PDF of the document as it is.
