# Refund / Cancel

This service checks whether the transaction is eligible for cancellation or refund, and then returns the `deeplink_url` and the `encryption_key`. To send a request to this service, a mobile session token (`session_key`) must be used.

## POST /v1/softpos/init\_reversal\_transaction

> Initiate Cancel / Refund

```json
{"openapi":"3.0.3","info":{"title":"PayPOS (Paynet) API","version":"1.0.0"},"tags":[{"name":"SoftPOS"}],"servers":[{"url":"https://api.paynet.com.tr","description":"Production"},{"url":"https://pts-api.paynet.com.tr","description":"Sandbox"}],"paths":{"/v1/softpos/init_reversal_transaction":{"post":{"summary":"Initiate Cancel / Refund","tags":["SoftPOS"],"parameters":[{"name":"Session-Key","in":"header","required":true,"description":"Mobile session key","schema":{"type":"string"}},{"$ref":"#/components/parameters/ContentTypeHeader"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InitReversalRequest"}}}},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InitReversalResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}},"components":{"parameters":{"ContentTypeHeader":{"name":"Content-Type","in":"header","required":true,"description":"Content type.","schema":{"type":"string"}}},"schemas":{"InitReversalRequest":{"type":"object","required":["xact_id"],"properties":{"xact_id":{"type":"string","description":"The encrypted version of the transaction ID."},"reference_no":{"type":"string","description":"Reference number."},"callback_url":{"type":"string","description":"Callback url.","nullable":true}}},"InitReversalResponse":{"type":"object","properties":{"payment_session_id":{"type":"string","description":"Payment session id."},"deeplink_url":{"type":"string","description":"Deeplink url."},"encryption_key":{"type":"string","description":"encryption key."},"object_name":{"type":"string","description":"Object name."},"code":{"type":"integer","description":"Code."},"message":{"type":"string","description":"Message."}}},"ErrorResponse":{"type":"object","properties":{"object_name":{"type":"string","description":"Object name."},"code":{"type":"integer","description":"Code."},"message":{"type":"string","description":"Message."}}}}}}
```
