Question

Create Board without registration error

  • 13 July 2021
  • 2 replies
  • 50 views

Badge +1

Hi! I’m trying to use the “Create Board without registration” button but it doesn’t work. Maybe, something wrong with JWT integration. Any ideas?
 

<script language="JavaScript" type="text/javascript"
src="https://kjur.github.io/jsrsasign/jsrsasign-latest-all-min.js">
</script>
<script type="text/javascript">
var oHeader = {alg: 'HS256', typ: 'JWT'};
// Payload
var oPayload = {};
var tNow = KJUR.jws.IntDate.get('now');
var tEnd = KJUR.jws.IntDate.get('now + 1day');
oPayload.iss = "CLIENT_ID";
oPayload.nbf = tNow;
oPayload.iat = tNow;
oPayload.exp = tEnd;
// Sign JWT, password=616161
var sHeader = JSON.stringify(oHeader);
var sPayload = JSON.stringify(oPayload);
var sJWT = KJUR.jws.JWS.sign("HS256", sHeader, sPayload, "CLIENT_SECRET");


</script>
<script>

function onClick() {
console.log(sJWT);
miroBoardsPicker.open({
clientId: 'CLIENT_ID', // 1) Put your 'clientId' here.
action: 'access-link',
allowCreateAnonymousBoards: true, //2) Enable this option
getToken: () => Promise.resolve(sJWT), // Provide token in async way
success: data => {
console.log('on success', data)
},
error: e => {
console.log('on error', e)
},
cancel: () => {
console.log('on cancel')
},

/*windowRef: windowRef,*/ // Optional. Link to an already opened popup window. See example below in case you want lazy loading for boardsPicker.js.
})
}

 


2 replies

Userlevel 4
Badge +6

Hi,

 

Live Embed offers 3 integration options:
(1) via direct-link (lets users copy-paste a Miro link into your product) - available in self-service.
(2) via boards-picker (launches a window for the users to select a new board or load an existing one) - available only on-demand.
(3) with editable boards without registration (user doesn't need to sign up or log in to launch an empty whiteboard) 
- available only on-demand.
 
To get access to (2) and (3) you need to open a request, you can find more information here.
 

Your account was enable for (2) but not for (3) that you are trying to use in your code:

allowCreateAnonymousBoards: true, //2) Enable this option 

 

The support team reached out to you by email.

Regards,

Anthony

 

 

Badge +1

Hello, 

 

If we would like to use option 3 with guarantee, is there a way to get it forever? Shall we use a certain subscription plan to get this?

Reply