Source code for fatsecret.resources._generated.profile

# AUTO-GENERATED by scripts/oas-sync emit-resource Profile Auth. Do not edit by hand.
"""Resource wrapper for the OAS ``Profile Auth`` tag (generated)."""

from __future__ import annotations

from typing import Any, Optional

from .._base import BaseResource


class ProfileResource(BaseResource):
    """Resource methods for the OAS `Profile Auth` tag (generated)."""

[docs] def create_v1( self, user_id: str, ) -> Any: """profile.create (v1). Premier-only.""" params: dict[str, Any] = {"method": "profile.create"} params["user_id"] = user_id payload = self._client._call(params, method="POST") return self._client._unwrap(payload, "profile")
[docs] def get_auth_v1( self, user_id: Optional[str] = None, ) -> Any: """profile.get_auth (v1). Premier-only.""" params: dict[str, Any] = {"method": "profile.get_auth"} self._client._set_optional( params, [ ("user_id", user_id), ], ) payload = self._client._call(params) return self._client._unwrap(payload, "profile")
[docs] def get_v1( self, ) -> Any: """profile.get (v1). Premier-only.""" params: dict[str, Any] = {"method": "profile.get"} payload = self._client._call(params) return self._client._unwrap(payload, "profile")
__all__ = ["ProfileResource"]