# Epay-Igs-Upay
`base_url` : `http://api-dev.evaly.com.bd/epay-igs-upay`
## Payments
### Payment Init
Method: `GET`
URL: `{base_url}/payments/init/{epay_payment_id}`
Response:
```status_code: 200```
```json=
{
"success": true,
"message": "Payment created!!",
"data": {
"gateway_url": "http://uat-pgw.upay.systems/16189043127588024/EVL474827229/",
"epay_payment_id": "e71371fc645347f390bc2f2d82ac0697"
}
}
```
### Payment Query
Method: `GET`
URL: `{base_url}/payments/query/{epay_payment_id}`
Response:
```status_code: 200```
```json=
{
"success": true,
"message": "Payment fetched!",
"data": {
"epay_payment_id": "28dde665ff214e059a58b21da2d55468",
"gateway_response": [],
"gateway": "nagad",
"status": "processing",
"initiated_at": "2021-04-14T17:49:56.346Z"
}
}
```
## Refunds
### Refund Init
Method: `POST`
URL: `{base_url}/refund/init`
Headers:
```json=
{
"secret-key": <secret key>
}
```
Request Body:
```json=
{
"gateway_payment_id":"6075a31101c3f30012549920",
"amount": 100,
"refund_operation_id": "1bw2asma2wkmkc"
}
```
Response:
```status_code: 201```
```json=
{
"success": true,
"message": "Refund created!!",
"data": {}
}
```