You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: remote_auth.go
    path of file: ./repos/meshery/server/models
    
    the code of the file until where you have to start completion: package models

import (
	"bytes"
	"crypto/rsa"
	"crypto/x509"
	"encoding/base64"
	"encoding/json"
	"encoding/pem"
	"fmt"
	"io"
	"math/big"
	"net/http"
	"net/url"
	"time"

	"github.com/golang-jwt/jwt"
	"github.com/sirupsen/logrus"
	"github.com/spf13/viper"
	"golang.org/x/oauth2
    
func (l *RemoteProvider) revokeToken(tokenString string) error {
	jsonData := make(map[string]string)
	token, err := l.DecodeTokenData(tokenString)

	if err != nil {
		return ErrTokenDecode(err)
	}

	jsonData["token"] = token.RefreshToken

	body, err := json.Marshal(jsonData)

	if err != nil {
		return ErrMarshal(err, "refresh token")
	}

	remoteURL, err := url.Parse(fmt.Sprintf("%s/revoke", l.RemoteProviderURL))
	if err != nil {
		logrus.Errorf("maformed url: %v", err)
		return err
	}
	r, err := http.Post(remoteURL.String(), "application/json", bytes.NewReader(body))

	if err != nil {
		logrus.Errorf("Error revoking token: %v", err)
		return err
	}

	if r.StatusCode != http.StatusOK {
		return ErrTokenRevoke(fmt.Errorf("failed to revoke token: status %d", r.StatusCode))
	}
	return nil
}