cancel
Showing results forย 
Search instead forย 
Did you mean:ย 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

post /api/2.0/sql/statements/sql statement id/cancel forbidden error in databricks

slakshmanan
New Contributor III

when i tried executing this request

post /api/2.0/sql/statements/${SQL_STATEMENT_ID}/cancel

I am getting forbidden error.

how do we get access to execute this

1 REPLY 1

filipniziol
Contributor

Hi @slakshmanan ,

The 403 Forbidden error usually means that the API request is not authorized, meaning you likely do not have the proper permissions or your authentication credentials are not being recognized. Here are 2 main reasons:

1. Missing or Incorrect Authentication Token
To execute REST API requests on Databricks, you need to authenticate using a Personal Access Token (PAT). Make sure that:

  • You have generated a valid PAT from your Databricks workspace settings.
  • You are including the PAT correctly in the request header.
Authorization: Bearer <YOUR_PERSONAL_ACCESS_TOKEN>

2. Insufficient Permissions

Make sure you have correct permissions


 

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you wonโ€™t want to miss the chance to attend and share knowledge.

If there isnโ€™t a group near you, start one and help create a community that brings people together.

Request a New Group