import base64


def oauth_basic_authentication(app_id, cert_id):
    """Get the basic authentication header string for OAuth2
    authentication based on App ID and Cert ID.
    """
    enc = base64.b64encode(f'{app_id}:{cert_id}'.encode('utf8'))
    return f'Basic {enc.decode()}'