Configuração do NFS-e Integration Client

 

Configuração do NFS-e Integration Server, arquivo de configuração “e-IntegrationServiceConfiguration.xml”.

 

e-IntegrationServiceConfiguration.xml:

 

<?xml version="1.0" encoding="utf-16"?>

<IntegrationService xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

 <ProductName>LotManager</ProductName>

 <Version>3.1.0</Version>

 <WebServiceConfig>

         <Url>https://krotonhl.e-datacenter.nddigital.com.br/NFSeWebService/ExchangeMessage.asmx</Url>

         <ProcessCode>30000</ProcessCode>

         <ExchangePattern>1</ExchangePattern>

         <MessageTypeSend>100</MessageTypeSend>

         <MessageTypeConsult>103</MessageTypeConsult>

         <MessageTypeDelete>102</MessageTypeDelete>

 </WebServiceConfig>

 <GlobalPropertyList/>

 <GlobalPropertyGroupList/>

 <Timers>

         <Timer>

                 <Job>

                         <Id>1</Id>

                         <JobKey>14000</JobKey>

                         <Name>HM_NFSE_KROTON_06255692000103_14000</Name>

                         <MaxRpsPerLot>2</MaxRpsPerLot>

                         <TimerToInsert>0</TimerToInsert>

                         <TimerToConsult>2</TimerToConsult>

                         <InputDirectory>C:\Program Files\NDDigital\NFSe\Targets\HM_NFSE_KROTON_06255692000103_14000</InputDirectory> // Diretório onde o Integration.Client pega os arquivos

                         <LotBreakDirectory>C:\Program Files\NDDigital\NFSe\Targets\HM_NFSE_KROTON_06255692000103_14000\LotBreak</LotBreakDirectory> // Diretório onde o Integration.Client larga os lotes quebrados e onde o processo de envio pega os lotes para enviar

                         <OutputDirectory>C:\Program Files\NDDigital\NFSe\Targets\HM_NFSE_KROTON_06255692000103_14000\Output</OutputDirectory> // Diretório onde o Integartion.Client salva as integracoes retornadas

                         <InputServerDirectory>C:\ToolsNFSe\Input\HM_NFSE_KROTON_06255692000103_14000</InputServerDirectory> // Diretório onde o Web Service larga os arquivos para o Integration.Server processar

                         <JobInputType>TXT</JobInputType>

                         <JobType>Output</JobType>

                         <CnpjPrestador>06255692000103</CnpjPrestador>

                         <MaxDocumentsReturn>10</MaxDocumentsReturn>

                 </Job>

                 <Id>TimerBreakLages</Id>

                 <Description>Timer</Description>

                 <BeginInitialTime>1</BeginInitialTime>

                 <Interval>2</Interval>

                 <Category/>

                 <Active>1</Active>

                 <Processes>

                         <Process Id="BreakRpsProcess"/>

                         <Process Id="SendMessageProcess"/>

                         <Process Id="ConsultMessageProcess"/>

                 </Processes>

         </Timer>

         <Timer>

                 <Job>

                         <Id>4</Id>

                         <JobKey>3000</JobKey>

                         <Name>HM_NFSE_KROTON_38733648002606_3000</Name>

                         <MaxRpsPerLot>500</MaxRpsPerLot>

                         <TimerToInsert>0</TimerToInsert>

                         <TimerToConsult>2</TimerToConsult>

                         <InputDirectory>C:\Program Files\NDDigital\NFSe\Targets\HM_NFSE_KROTON_38733648002606_3000</InputDirectory> // Diretório onde o Integration.Client pega os arquivos

                         <LotBreakDirectory>C:\Program Files\NDDigital\NFSe\Targets\HM_NFSE_KROTON_38733648002606_3000\LotBreak</LotBreakDirectory> // Diretório onde o Integration.Client larga os lotes quebrados e onde o processo de envio pega os lotes para enviar

                         <OutputDirectory>C:\Program Files\NDDigital\NFSe\Targets\HM_NFSE_KROTON_38733648002606_3000\Output</OutputDirectory> // Diretório onde o Integartion.Client salva as integracoes retornadas

                         <InputServerDirectory>C:\ToolsNFSe\Input\HM_NFSE_KROTON_38733648002606_3000</InputServerDirectory> // Diretório onde o Web Service larga os arquivos para o Integration.Server processar

                         <JobInputType>TXT</JobInputType>

                         <JobType>Output</JobType>

                         <CnpjPrestador>38733648002606</CnpjPrestador>

                         <MaxDocumentsReturn>10</MaxDocumentsReturn>

                 </Job>

                 <Id>TimerBreakLages</Id>

                 <Description>Timer</Description>

                 <BeginInitialTime>1</BeginInitialTime>

                 <Interval>2</Interval>

                 <Category/>

                 <Active>1</Active>

                 <Processes>

                         <Process Id="BreakRpsProcess"/>

                         <Process Id="SendMessageProcess"/>

                         <Process Id="ConsultMessageProcess"/>

                 </Processes>

         </Timer>

 </Timers>

 <Processes>

         <Process Id="BreakRpsProcess">

                 <Description>BreakRps</Description>

                 <AssemblyPath>C:\Program Files\NDDigital\NFSe\NFSeIntegrationClient.LotTransfer\NDDigital.eIntegrationClient.NFSe.LotTransfer.dll</AssemblyPath>

                 <ClassName>NDDigital.eIntegrationClient.NFSe.LotTransfer.Processes.BreakRpsProcess</ClassName>

                 <Product>LotManager</Product>

                 <GlobalPropertyIdList/>

                 <Properties>

                 </Properties>

         </Process>

         <Process Id="SendMessageProcess">

                 <Description>SendMessage</Description>

                 <AssemblyPath>C:\Program Files\NDDigital\NFSe\NFSeIntegrationClient.LotTransfer\NDDigital.eIntegrationClient.NFSe.LotTransfer.dll</AssemblyPath>

                 <ClassName>NDDigital.eIntegrationClient.NFSe.LotTransfer.Processes.SendMessageProcess</ClassName>

                 <Product>LotManager</Product>

                 <GlobalPropertyIdList/>

                 <Properties>

                 </Properties>

         </Process>

         <Process Id="ConsultMessageProcess">

                 <Description>SendMessage</Description>

                 <AssemblyPath>C:\Program Files\NDDigital\NFSe\NFSeIntegrationClient.LotTransfer\NDDigital.eIntegrationClient.NFSe.LotTransfer.dll</AssemblyPath>

                 <ClassName>NDDigital.eIntegrationClient.NFSe.LotTransfer.Processes.ConsultMessageProcess</ClassName>

                 <Product>LotManager</Product>

                 <GlobalPropertyIdList/>

                 <Properties>

                 </Properties>

         </Process>

 </Processes>

</EIntegrationService>

 

Detalhamento do e-IntegrationServiceConfiguration.xml:

 

Configuração do NFS-e Integration Client

A01 Raiz - TAG Raiz do arquivo de configuração

#

ID

Campo

Descrição

Elemento

Pai

Observação

A01

<EIntegrationService>

 

G

-

TAG Raiz da configuração do WS

2

A02

<ProductName>

Nome do produto

E

A01

Ex.: LotManager

3

A03

<Version>

Versão

E

A01

Ex.: 3.1.0

4

B01

<WebServiceConfig>

Grupo de informações da mensagem

G

A01

 

5

B02

<Url>

Endereço do Web Service.

E

B01

Ex.: https://krotonhl.e-datacenter.nddigital.com.br/NFSeWebService/ExchangeMessage.asmx

6

B03

<ProcessCode>

Código do processo de envio de RPS

E

B01

Ex.: 30000

7

B04

<ExchangePattern>

Padrão de troca de mensagem

E

B01

Ex.: 1, envio de mensagem síncrono.

8

B05

<MessageTypeSend>

Tipo de operação de envio de lotes

E

B01

Ex.: 100 – Envio de Lote pelo Web Services

9

B06

<MessageTypeConsult>

Tipo de operação de consulta de documento de integração

E

B01

Ex.: 103 – Consulta de Retorno de Lote.

10

B07

< MessageTypeDelete >

Tipo de operação de exclusão de documento de integração

E

B01

Ex.: 102 – Deleta a integração da base de dados.

11

B08

<GlobalPropertyList>

 

E

B01

 

12

B09

<GlobalPropertyGroupList>

 

E

B01

 

13

C01

<Timers>

 

G

A01

 

14

C02

<Timer>

 

G

C01

Obs.: Esta tag deverá ser repetida para os demais Jobs configurados, com as respectivas configurações filhas da tag.

15

C03

<Job>

 

G

C02

O Job deve ser configurado conforme o Job cadastrado no settings

16

C04

<Id>

Identifica o numero do job

E

C03

 

17

C05

<JobKey>

Identifica a chave do job na base de dados, para cada job terá um número inteiro deve ser sempre uma milhar exata

E

C03

Ex.: 1000. 2000. 3000 ...

18

C06

<Name>

Nome do Job

E

C03

Ex.: Job de Lages

19

C07

<MaxRpsPerLot>

Define quantos documentos serão inseridos em cada lote.

E

C03

Informar número inteiro para quantidade de RPS que formara cada lote.

20

C08

<TimerToInsert>

 

E

C03

Não esta sendo usado

21

C09

<TimerToConsult>

Configura o tempo ate a próxima consulta.

E

C03

Tempo em minutos para a próxima consulta, Ex.: 2

22

C10

<InputDirectory>

Diretório onde os arquivos de lote do cliente será gravado

E

C03

Ex.:C:\Diretorio\NDDigital\NFSe\Targets\Nome_do_job

23

C11

<LotBreakDirectory>

Diretório onde são gravados os arquivos para envio ao WS do Data Center.

E

C03

Ex.:C:\Diretorio\NDDigital\NFSe\Targets\Nome_do_job \LotBreak

24

C12

<OutputDirectory>

Diretório onde são salvos os documentos de integração retornados

E

C03

Ex.:C:\Diretorio\NDDigital\NFSe\Targets\Nome_do_job\Output

25

C13

<InputServerDirectory>

Diretório no servidor Data Center onde serão gravados os arquivos para serem processados

E

C03

Ex.: C:\ToolsNFSe\Input\Nome_do_job

26

C14

<JobInputType>

Tipo de arquivo texto (TXT)

E

C03

Ex.: TXT

27

C15

<JobType>

Tipo de Job

E

C03

Ex.: Output

28

C16

<CnpjPrestador>

CNPJ do prestador de serviços

E

C03

CNPJ do prestador.

29

C17

<MaxDocumentsReturn>

Número de documentos que serão retornados.

E

C03

Configura quantos documentos de integração será retornado em cada lote.

30

C18

<Id>

Identificador do Timer

E

C02

Ex.: TimerBreakLages

31

C19

<Description>

Descrição do Timer

E

C02

Ex.: timer

32

C20

<BeginInitialTime>

Refere-se ao tempo em segundos que a Thread irá aguardar antes de iniciar sua execução

E

C02

Tempo em segundos para iniciar a execução, Ex.: 1

33

C21

<Interval>

Tempo que ate a próxima consulta.

E

C02

Tempo em minutos para próxima consulta, Ex.: 2

34

C22

<Category>

 

E

C02

 

35

C23

<Active>

Indica se o timer está ativo

E

C02

0 = Inativo, 1 = Ativo.

36

D01

<Processes>

 

G

C02

 

37

D02

<Process Id>

Identifica o processo que será executado.

E

D01

Ex.: Id = BreakRpsProcess

38

D03

<Process Id>

Identifica o processo que será executado.

E

D01

Ex.: Id = SendMessageProcess

39

D04

<Process Id>

Identifica o processo que será executado.

E

D01

Ex.: Id = ConsultMessageProcess

40

E01

<Processes>

 

G

A01

 

41

E02

<Process Id>

Identifica o processo que será executado.

G

E01

Id = BreakRpsProcess

44

E03

<Description>

Descrição do processo

E

E02

Ex.: BreakRPS

45

E04

<AssemblyPath>

Configuração da dll que será usada

E

E02

Ex.: C:\Program Files\NDDigital\NFSe\NFSeIntegrationClient.LotTransfer\NDDigital.eIntegrationClient.NFSe.LotTransfer.dll

46

E05

<ClassName>

Configuração da classe que será usada para o processamento

E

E02

Ex.:NDDigital.eIntegrationClient.NFSe.LotTransfer.Processes.BreakRpsProcess

47

E06

<Product>

Nome do produto gerenciador de lote

E

E02

Ex.: LotManager

48

E07

<GlobalPropertyIdList>

 

E

E02

 

49

E08

<Properties>

 

E

E02

 

50

E09

<Process Id>

 

G

E01

Id = SendMessageProcess

51

E10

<Description>

Descrição do processo

E

E09

Ex.: BreakRPS

52

E11

<AssemblyPath>

Configuração da dll que será usada

E

E09

Ex.: C:\Program Files\NDDigital\NFSe\NFSeIntegrationClient.LotTransfer\NDDigital.eIntegrationClient.NFSe.LotTransfer.dll

53

E12

<ClassName>

Configuração da classe que será usada para o processamento

E

E09

Ex.:NDDigital.eIntegrationClient.NFSe.LotTransfer.Processes.SendMessageProcess

54

E13

<Product>

Nome do produto gerenciador de lote

E

E09

Ex.: LotManager

55

E14

<GlobalPropertyIdList>

 

E

E09

 

56

E15

<Properties>

 

E

E09

 

57

E16

<Process Id>

 

G

E01

Id = ConsultMessageProcess

58

E17

<Description>

Descrição do processo

E

E16

Ex.: BreakRPS

59

E18

<AssemblyPath>

Configuração da dll que será usada

E

E16

Ex.: C:\Program Files\NDDigital\NFSe\NFSeIntegrationClient.LotTransfer\NDDigital.eIntegrationClient.NFSe.LotTransfer.dll

60

E19

<ClassName>

Configuração da classe que será usada para o processamento

E

E16

Ex.:NDDigital.eIntegrationClient.NFSe.LotTransfer.Processes.ConsultMessageProcess

61

E20

<Product>

Nome do produto gerenciador de lote

E

E16

Ex.: LotManager

62

E21

<GlobalPropertyIdList>

 

E

E16

 

63

E22

<Properties>

 

E

E16