public Guid IssueAccessToken() { var accessToken = Guid.NewGuid(); AccessTokens.Add(accessToken); return(accessToken); }
/// <summary> /// Add Oauth2 token to the bombardier generator /// </summary> /// <param name="token"></param> /// <param name="authenticationType"></param> /// <returns></returns> public BombardierGeneratorOptions AddOAuth2Token(string token, AuthenticationType authenticationType) { if (string.IsNullOrEmpty(token)) { throw new ArgumentException($"{nameof(token)} is null."); } if (authenticationType == null) { throw new ArgumentException($"{nameof(authenticationType)} is null."); } AccessTokens.Add(authenticationType, token); return(this); }