Skip to content

Commit d0d81bb

Browse files
authored
Update README.md
1 parent 631229c commit d0d81bb

File tree

1 file changed

+40
-40
lines changed

1 file changed

+40
-40
lines changed

README.md

Lines changed: 40 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -2,105 +2,105 @@
22

33
# VerifyCat
44

5-
**VerifyCat** is a versatile validation API designed to handle various types of validations, including CPF (Brazilian ID number), CNPJ (Brazilian legal entity number), URL, email, and credit card numbers.
5+
**VerifyCat** é uma API de validação versátil projetada para lidar com vários tipos de validações, incluindo CPF, CNPJ, URL, E-mails e números de cartão de crédito (até o momento).
66

7-
## Table of Contents
7+
## Sumário
88

9-
- [Overview](#overview)
10-
- [Architecture](#architecture)
11-
- [API Endpoints](#api-endpoints)
12-
- [Usage](#usage)
13-
- [Contributing](#contributing)
14-
- [License](#license)
9+
- [Visão Geral](#visão-geral)
10+
- [Arquitetura](#arquitetura)
11+
- [Endpoints da API](#endpoints-da-api)
12+
- [Uso](#uso)
13+
- [Contribuições](#contribuições)
14+
- [Licença](#licença)
1515

16-
## Overview
16+
## Visão Geral
1717

18-
VerifyCat is built using the [Gin](https://github.com/gin-gonic/gin) framework for handling HTTP requests and providing a fast and efficient web server. The project is structured to accommodate different validation types, each implemented in a separate file within the `validate` package.
18+
VerifyCat é construído usando o framework [Gin](https://github.com/gin-gonic/gin) para lidar com solicitações HTTP e fornecer um servidor web rápido e eficiente. O projeto é estruturado para acomodar diferentes tipos de validação, cada um implementado em um arquivo separado dentro do pacote `validate`.
1919

20-
## Architecture
20+
## Arquitetura
2121

22-
The main entry point of the application is the `verifycat_api.go` file. It sets up the Gin router and defines the endpoint for validation at `/validate`. The validation logic is delegated to specific handlers in the `validate` package.
22+
O ponto de entrada principal da aplicação é o arquivo `verifycat_api.go`. Ele configura o roteador Gin e define o endpoint para validação em `/validate`. A lógica de validação é delegada para manipuladores específicos no pacote `validate`.
2323

24-
The `validate` package contains individual files (`cpf.go`, `cnpj.go`, `url.go`, `email.go`, and `creditcard.go`) for each validation type. These files house the validation logic and request handling specific to their validation type.
24+
O pacote `validate` contém arquivos individuais (`cpf.go`, `cnpj.go`, `url.go`, `email.go` e `creditcard.go`) para cada tipo de validação. Esses arquivos contêm a lógica de validação e manipulação de solicitações específicas para seu tipo de validação.
2525

26-
## API Endpoints
26+
## Endpoints da API
2727

2828
### `POST /validate`
2929

30-
This endpoint supports validation for various types of data. The payload should be in JSON format, containing the `type` (validation type) and `value` (data to be validated).
30+
Este endpoint suporta validação para vários tipos de dados. A carga útil deve estar no formato JSON, contendo o `type` (tipo de validação) e `value` (dados a serem validados).
3131

32-
- **Request Payload Example:**
32+
- **Exemplo de Carga Útil da Solicitação:**
3333
```json
3434
{
3535
"type": "cpf",
3636
"value": "123.456.789-09"
3737
}
3838
```
3939

40-
- **Response Example:**
40+
- **Exemplo de Resposta:**
4141
```json
4242
{
4343
"isValid": true,
4444
"message": "CPF"
4545
}
4646
```
4747

48-
### CURL Request Example
48+
### Exemplo de Solicitação CURL
4949

5050
```bash
5151
curl -X POST http://localhost:8080/validate -H "Content-Type: application/json" -d '{"type": "cpf", "value": "123.456.789-09"}'
5252
```
5353

54-
- **CURL Response Example:**
54+
- **Exemplo de Resposta CURL:**
5555
```json
5656
{
5757
"isValid": true,
5858
"message": "CPF"
5959
}
6060
```
6161

62-
### Supported Validation Types
62+
### Tipos de Validação Suportados
6363

64-
- `cpf`: Brazilian ID number
65-
- `cnpj`: Brazilian legal entity number
64+
- `cpf`: Número de identificação brasileiro (CPF)
65+
- `cnpj`: Número de entidade legal brasileira (CNPJ)
6666
- `url`: URL
67-
- `email`: Email address
68-
- `creditcard`: Credit card number
67+
- `email`: Endereço de e-mail
68+
- `creditcard`: Número de cartão de crédito
6969

70-
## RESTful Architecture
70+
## Arquitetura RESTful
7171

72-
The API VerifyCat follows the principles of REST, including:
72+
A API VerifyCat segue os princípios RESTful, incluindo:
7373

74-
- **Identifiable Resources:** Each validation type (CPF, CNPJ, URL, etc.) is treated as an identifiable resource. Operations are performed on these resources through specific URLs.
74+
- **Recursos Identificáveis:** Cada tipo de validação (CPF, CNPJ, URL, etc.) é tratado como um recurso identificável. As operações são realizadas nesses recursos por meio de URLs específicos.
7575

76-
- **Standard HTTP Operations:** CRUD operations (Create, Read, Update, Delete) are mapped to standard HTTP operations. In this code, the main operation is validation, performed through a POST request to the `/validate` resource.
76+
- **Operações HTTP Padrão:** Operações CRUD (Criar, Ler, Atualizar, Excluir) são mapeadas para operações HTTP padrão. Neste código, a principal operação é a validação, realizada por meio de uma solicitação POST para o recurso `/validate`.
7777

78-
- **Statelessness:** Each client request to the server contains all the information needed to understand and process the request. There is no dependency on intermediate states between requests.
78+
- **Estado Sem Sessão:** Cada solicitação do cliente ao servidor contém todas as informações necessárias para entender e processar a solicitação. Não há dependência de estados intermediários entre solicitações.
7979

80-
- **Resource Representation:** Resources are represented in JSON in the body of HTTP responses. The response is a representation of the current state of the resource (e.g., whether a CPF is valid or not).
80+
- **Representação de Recursos:** Os recursos são representados em JSON no corpo das respostas HTTP. A resposta é uma representação do estado atual do recurso (por exemplo, se um CPF é válido ou não).
8181

82-
- **HATEOAS (Hypermedia As The Engine Of Application State):** While the provided code does not explicitly include links to other resources in the HATEOAS style, the concept is embedded in the general principle that the client interacts with the API through representations of resources and states provided in responses.
82+
- **HATEOAS (Hypermedia As The Engine Of Application State):** Embora o código fornecido não inclua explicitamente links para outros recursos no estilo HATEOAS, o conceito está incorporado no princípio geral de que o cliente interage com a API por meio de representações de recursos e estados fornecidos em respostas.
8383

84-
## Usage
84+
## Uso
8585

86-
1. **Clone the Repository:**
86+
1. **Clone o Repositório:**
8787
```bash
8888
git clone https://github.com/your-username/verifycat.git
8989
cd verifycat
9090
```
9191

92-
2. **Run the Application:**
92+
2. **Execute a Aplicação:**
9393
```bash
9494
go run verifycat_api.go
9595
```
9696

97-
3. **Make API Requests:**
98-
- Use your preferred API client (e.g., cURL, Postman) to send POST requests to `http://localhost:8080/validate` with the appropriate payload.
97+
3. **Faça Solicitações à API:**
98+
- Use seu cliente de API preferido (por exemplo, cURL, Postman) para enviar solicitações POST para `http://localhost:8080/validate` com a carga útil apropriada.
9999

100-
## Contributing
100+
## Contribuições
101101

102-
Feel free to contribute by opening issues, providing feedback, or submitting pull requests.
102+
Sinta-se à vontade para contribuir abrindo problemas, fornecendo feedback ou enviando pull requests.
103103

104-
## License
104+
## Licença
105105

106-
This project is licensed under the AGPL V3 License - see the [LICENSE](LICENSE) file for details.
106+
Este projeto está licenciado sob a Licença AGPL V3 - consulte o arquivo [LICENSE](LICENSE) para obter detalhes.

0 commit comments

Comments
 (0)