# Delete notification DELETE https://api-sandbox.payabli.com/api/Notification/{nId} Deletes a single notification or autogenerated report. Reference: https://docs.payabli.com/developers/api-reference/notification/delete-notification ## OpenAPI Specification ```yaml openapi: 3.1.1 info: title: Delete notification version: endpoint_notification.DeleteNotification paths: /Notification/{nId}: delete: operationId: delete-notification summary: Delete notification description: Deletes a single notification or autogenerated report. tags: - - subpackage_notification parameters: - name: nId in: path description: 'Notification ID. ' required: true schema: type: string - name: requestToken in: header required: true schema: type: string responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/type_:PayabliApiResponseNotifications' '400': description: Bad request/ invalid data content: {} '401': description: Unauthorized request. content: {} '500': description: Internal API Error content: {} '503': description: Database connection error content: {} components: schemas: type_:IsSuccess: type: boolean type_:PageIdentifier: type: string type_:Responsecode: type: integer type_:PayabliApiResponseNotificationsResponseData: oneOf: - type: integer - type: string type_:ResponseText: type: string type_:PayabliApiResponseNotifications: type: object properties: isSuccess: $ref: '#/components/schemas/type_:IsSuccess' description: >- If `isSuccess` = true, `responseData` contains the notification identifier. If `isSuccess` = false, `responseData` contains the reason for the error. pageIdentifier: $ref: '#/components/schemas/type_:PageIdentifier' responseCode: $ref: '#/components/schemas/type_:Responsecode' responseData: $ref: >- #/components/schemas/type_:PayabliApiResponseNotificationsResponseData description: >- When the request was successful, this contains the notification ID, or `nID` used to manage the notification. responseText: $ref: '#/components/schemas/type_:ResponseText' required: - responseText ``` ## SDK Code Examples ```python Delete from payabli import payabli client = payabli( api_key="YOUR_API_KEY", ) client.notification.delete_notification( n_id="1717", ) ``` ```typescript Delete import { PayabliClient } from "@payabli/sdk-node"; const client = new PayabliClient({ apiKey: "YOUR_API_KEY" }); await client.notification.deleteNotification("1717"); ``` ```go Delete import ( context "context" option "github.com/payabli/sdk-go/option" sdkgoclient "github.com/payabli/sdk-go/client" ) client := sdkgoclient.NewClient( option.WithApiKey( "", ), ) response, err := client.Notification.DeleteNotification( context.TODO(), "1717", ) ``` ```csharp Delete using PayabliApi; var client = new PayabliApiClient("API_KEY"); await client.Notification.DeleteNotificationAsync("1717"); ``` ```ruby Delete require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/Notification/1717") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Delete.new(url) request["requestToken"] = '' response = http.request(request) puts response.read_body ``` ```java Delete HttpResponse response = Unirest.delete("https://api-sandbox.payabli.com/api/Notification/1717") .header("requestToken", "") .asString(); ``` ```php Delete request('DELETE', 'https://api-sandbox.payabli.com/api/Notification/1717', [ 'headers' => [ 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```swift Delete import Foundation let headers = ["requestToken": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/Notification/1717")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "DELETE" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```