code: func RootCAFromAPI(ctx context.Context, apiRootCA *api.RootCA, expiry time.Duration) (RootCA, error) {
  	var intermediates []byte
  	signingCert := apiRootCA.CACert
  	signingKey := apiRootCA.CAKey
  	if apiRootCA.RootRotation != nil {
  		signingCert = apiRootCA.RootRotation.CrossSignedCACert
  		signingKey = apiRootCA.RootRotation.CAKey
  		intermediates = apiRootCA.RootRotation.CrossSignedCACert
  	}
  	if signingKey == nil {
  		signingCert = nil
  	}
  	return NewRootCA(apiRootCA.CACert, signingCert, signingKey, expiry, intermediates)
  }
docs: // RootCAFromAPI creates a RootCA object from an api.RootCA object