public WebhookSharedSecret resetSharedSecret ( long webhookId ) throws SmartsheetException { HttpRequest request = createHttpRequest ( this . getSmartsheet ( ) . getBaseURI ( ) . resolve ( "webhooks/" + webhookId + "/resetsharedsecret" ) , HttpMethod . POST ) ; HttpResponse response = getSmartsheet ( ) . getHttpClient ( ) . request ( request ) ; WebhookSharedSecret secret = null ; switch ( response . getStatusCode ( ) ) { case 200 : try { secret = this . smartsheet . getJsonSerializer ( ) . deserialize ( WebhookSharedSecret . class , response . getEntity ( ) . getContent ( ) ) ; } catch ( JsonParseException e ) { throw new SmartsheetException ( e ) ; } catch ( JsonMappingException e ) { throw new SmartsheetException ( e ) ; } catch ( IOException e ) { throw new SmartsheetException ( e ) ; } break ; default : handleError ( response ) ; } getSmartsheet ( ) . getHttpClient ( ) . releaseConnection ( ) ; return secret ; }
Resets the shared secret for the specified Webhook . For more information about how a shared secret is used see Authenticating Callbacks .