My Products
Help
SitterIT
CONTRIBUTOR ***

Cant release customer payment with new token

by SitterIT

When doing a POST https://integration.visma.net/API/controller/api/v1/customerpayment/400013/action/release

with body like :

{
  "type": {
    "Value""Payment"
  }
}
 
SitterIT_0-1692948948641.png

I get error 403 - Forbidden

SitterIT_1-1692948994840.png

 

 

If I just change to the old static token the same request works fine. All scopes are allowed in the app.

 

5 REPLIES 5
SitterIT
CONTRIBUTOR ***

by SitterIT

Thanx. This is also needed to create new Segments.

Accepted solution
Yıldırım
VISMA

by Yıldırım (Updated ‎29-08-2023 14:11 by Yıldırım VISMA )

Hi Sitter, after some testing, I was able to Release it without error:  "Scope requirement not met"

 

POST:
https://integration.visma.net/API/controller/api/v1/customerPayment/400069/action/release

RequestBody:
{
	"type": {
		"value": "Payment"
	}	
}

 

 

You should grant "vismanet_erp_service_api:update" scope to your application and generate a new token after. (including that scope in the token request together with read - write - delete)


update_Visma Developer Portal.jpg

-Generate Token Service Type Prod - Visma.Net API.jpg

SitterIT
CONTRIBUTOR ***

by SitterIT

I have that. Creating new token, works well to create new invoice, read customers, suppliers and more. I can also create the payment, but the action release will not work

 

SitterIT_0-1692968874916.png

 

SitterIT_1-1692969048114.png

 

SitterIT_2-1692969067383.png

SitterIT_3-1692969118032.png

 

 

Still get error 403 - Forbidden message=Scope requirement not met

 

SitterIT_4-1692969567133.png

 

 

Yıldırım
VISMA

by Yıldırım

I see, thanks for the information. Perhaps this is also related to user access issue connected with service_type token. 
We'll investigate this and prepare a fix. 

Yıldırım
VISMA

by Yıldırım (Updated ‎25-08-2023 13:36 by Yıldırım VISMA )

Hi,
1) Please make sure that Tenant(company) has granted the following scopes.  (Service_Type Applicaton Example, if your application is web application then follow the same steps for the Interactive_API type.)

 scopes_Visma Developer Portal.jpg

2) Generate a token with the granted scopes.

-Generate Token Service Type Prod - Visma.Net API.jpg