// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.

package provider

import (
	"context"
	"fmt"
	speakeasy_int64planmodifier "github.com/airbytehq/terraform-provider-airbyte/internal/planmodifiers/int64planmodifier"
	speakeasy_listplanmodifier "github.com/airbytehq/terraform-provider-airbyte/internal/planmodifiers/listplanmodifier"
	speakeasy_objectplanmodifier "github.com/airbytehq/terraform-provider-airbyte/internal/planmodifiers/objectplanmodifier"
	speakeasy_stringplanmodifier "github.com/airbytehq/terraform-provider-airbyte/internal/planmodifiers/stringplanmodifier"
	tfTypes "github.com/airbytehq/terraform-provider-airbyte/internal/provider/types"
	"github.com/airbytehq/terraform-provider-airbyte/internal/sdk"
	"github.com/airbytehq/terraform-provider-airbyte/internal/sdk/models/operations"
	"github.com/hashicorp/terraform-plugin-framework-validators/stringvalidator"
	"github.com/hashicorp/terraform-plugin-framework/path"
	"github.com/hashicorp/terraform-plugin-framework/resource"
	"github.com/hashicorp/terraform-plugin-framework/resource/schema"
	"github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier"
	"github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier"
	"github.com/hashicorp/terraform-plugin-framework/schema/validator"
	"github.com/hashicorp/terraform-plugin-framework/types"
	"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
)

// Ensure provider defined types fully satisfy framework interfaces.
var _ resource.Resource = &SourcePokeapiResource{}
var _ resource.ResourceWithImportState = &SourcePokeapiResource{}

func NewSourcePokeapiResource() resource.Resource {
	return &SourcePokeapiResource{}
}

// SourcePokeapiResource defines the resource implementation.
type SourcePokeapiResource struct {
	client *sdk.SDK
}

// SourcePokeapiResourceModel describes the resource data model.
type SourcePokeapiResourceModel struct {
	Configuration      tfTypes.SourcePokeapi               `tfsdk:"configuration"`
	CreatedAt          types.Int64                         `tfsdk:"created_at"`
	DefinitionID       types.String                        `tfsdk:"definition_id"`
	Name               types.String                        `tfsdk:"name"`
	ResourceAllocation *tfTypes.ScopedResourceRequirements `tfsdk:"resource_allocation"`
	SecretID           types.String                        `tfsdk:"secret_id"`
	SourceID           types.String                        `tfsdk:"source_id"`
	SourceType         types.String                        `tfsdk:"source_type"`
	WorkspaceID        types.String                        `tfsdk:"workspace_id"`
}

func (r *SourcePokeapiResource) Metadata(ctx context.Context, req resource.MetadataRequest, resp *resource.MetadataResponse) {
	resp.TypeName = req.ProviderTypeName + "_source_pokeapi"
}

func (r *SourcePokeapiResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse) {
	resp.Schema = schema.Schema{
		MarkdownDescription: "SourcePokeapi Resource",
		Attributes: map[string]schema.Attribute{
			"configuration": schema.SingleNestedAttribute{
				Required: true,
				PlanModifiers: []planmodifier.Object{
					speakeasy_objectplanmodifier.SuppressDiff(speakeasy_objectplanmodifier.ExplicitSuppress),
				},
				Attributes: map[string]schema.Attribute{
					"pokemon_name": schema.StringAttribute{
						Required:    true,
						Description: `Pokemon requested from the API. must be one of ["bulbasaur", "ivysaur", "venusaur", "charmander", "charmeleon", "charizard", "squirtle", "wartortle", "blastoise", "caterpie", "metapod", "butterfree", "weedle", "kakuna", "beedrill", "pidgey", "pidgeotto", "pidgeot", "rattata", "raticate", "spearow", "fearow", "ekans", "arbok", "pikachu", "raichu", "sandshrew", "sandslash", "nidoranf", "nidorina", "nidoqueen", "nidoranm", "nidorino", "nidoking", "clefairy", "clefable", "vulpix", "ninetales", "jigglypuff", "wigglytuff", "zubat", "golbat", "oddish", "gloom", "vileplume", "paras", "parasect", "venonat", "venomoth", "diglett", "dugtrio", "meowth", "persian", "psyduck", "golduck", "mankey", "primeape", "growlithe", "arcanine", "poliwag", "poliwhirl", "poliwrath", "abra", "kadabra", "alakazam", "machop", "machoke", "machamp", "bellsprout", "weepinbell", "victreebel", "tentacool", "tentacruel", "geodude", "graveler", "golem", "ponyta", "rapidash", "slowpoke", "slowbro", "magnemite", "magneton", "farfetchd", "doduo", "dodrio", "seel", "dewgong", "grimer", "muk", "shellder", "cloyster", "gastly", "haunter", "gengar", "onix", "drowzee", "hypno", "krabby", "kingler", "voltorb", "electrode", "exeggcute", "exeggutor", "cubone", "marowak", "hitmonlee", "hitmonchan", "lickitung", "koffing", "weezing", "rhyhorn", "rhydon", "chansey", "tangela", "kangaskhan", "horsea", "seadra", "goldeen", "seaking", "staryu", "starmie", "mrmime", "scyther", "jynx", "electabuzz", "magmar", "pinsir", "tauros", "magikarp", "gyarados", "lapras", "ditto", "eevee", "vaporeon", "jolteon", "flareon", "porygon", "omanyte", "omastar", "kabuto", "kabutops", "aerodactyl", "snorlax", "articuno", "zapdos", "moltres", "dratini", "dragonair", "dragonite", "mewtwo", "mew", "chikorita", "bayleef", "meganium", "cyndaquil", "quilava", "typhlosion", "totodile", "croconaw", "feraligatr", "sentret", "furret", "hoothoot", "noctowl", "ledyba", "ledian", "spinarak", "ariados", "crobat", "chinchou", "lanturn", "pichu", "cleffa", "igglybuff", "togepi", "togetic", "natu", "xatu", "mareep", "flaaffy", "ampharos", "bellossom", "marill", "azumarill", "sudowoodo", "politoed", "hoppip", "skiploom", "jumpluff", "aipom", "sunkern", "sunflora", "yanma", "wooper", "quagsire", "espeon", "umbreon", "murkrow", "slowking", "misdreavus", "unown", "wobbuffet", "girafarig", "pineco", "forretress", "dunsparce", "gligar", "steelix", "snubbull", "granbull", "qwilfish", "scizor", "shuckle", "heracross", "sneasel", "teddiursa", "ursaring", "slugma", "magcargo", "swinub", "piloswine", "corsola", "remoraid", "octillery", "delibird", "mantine", "skarmory", "houndour", "houndoom", "kingdra", "phanpy", "donphan", "porygon2", "stantler", "smeargle", "tyrogue", "hitmontop", "smoochum", "elekid", "magby", "miltank", "blissey", "raikou", "entei", "suicune", "larvitar", "pupitar", "tyranitar", "lugia", "ho-oh", "celebi", "treecko", "grovyle", "sceptile", "torchic", "combusken", "blaziken", "mudkip", "marshtomp", "swampert", "poochyena", "mightyena", "zigzagoon", "linoone", "wurmple", "silcoon", "beautifly", "cascoon", "dustox", "lotad", "lombre", "ludicolo", "seedot", "nuzleaf", "shiftry", "taillow", "swellow", "wingull", "pelipper", "ralts", "kirlia", "gardevoir", "surskit", "masquerain", "shroomish", "breloom", "slakoth", "vigoroth", "slaking", "nincada", "ninjask", "shedinja", "whismur", "loudred", "exploud", "makuhita", "hariyama", "azurill", "nosepass", "skitty", "delcatty", "sableye", "mawile", "aron", "lairon", "aggron", "meditite", "medicham", "electrike", "manectric", "plusle", "minun", "volbeat", "illumise", "roselia", "gulpin", "swalot", "carvanha", "sharpedo", "wailmer", "wailord", "numel", "camerupt", "torkoal", "spoink", "grumpig", "spinda", "trapinch", "vibrava", "flygon", "cacnea", "cacturne", "swablu", "altaria", "zangoose", "seviper", "lunatone", "solrock", "barboach", "whiscash", "corphish", "crawdaunt", "baltoy", "claydol", "lileep", "cradily", "anorith", "armaldo", "feebas", "milotic", "castform", "kecleon", "shuppet", "banette", "duskull", "dusclops", "tropius", "chimecho", "absol", "wynaut", "snorunt", "glalie", "spheal", "sealeo", "walrein", "clamperl", "huntail", "gorebyss", "relicanth", "luvdisc", "bagon", "shelgon", "salamence", "beldum", "metang", "metagross", "regirock", "regice", "registeel", "latias", "latios", "kyogre", "groudon", "rayquaza", "jirachi", "deoxys", "turtwig", "grotle", "torterra", "chimchar", "monferno", "infernape", "piplup", "prinplup", "empoleon", "starly", "staravia", "staraptor", "bidoof", "bibarel", "kricketot", "kricketune", "shinx", "luxio", "luxray", "budew", "roserade", "cranidos", "rampardos", "shieldon", "bastiodon", "burmy", "wormadam", "mothim", "combee", "vespiquen", "pachirisu", "buizel", "floatzel", "cherubi", "cherrim", "shellos", "gastrodon", "ambipom", "drifloon", "drifblim", "buneary", "lopunny", "mismagius", "honchkrow", "glameow", "purugly", "chingling", "stunky", "skuntank", "bronzor", "bronzong", "bonsly", "mimejr", "happiny", "chatot", "spiritomb", "gible", "gabite", "garchomp", "munchlax", "riolu", "lucario", "hippopotas", "hippowdon", "skorupi", "drapion", "croagunk", "toxicroak", "carnivine", "finneon", "lumineon", "mantyke", "snover", "abomasnow", "weavile", "magnezone", "lickilicky", "rhyperior", "tangrowth", "electivire", "magmortar", "togekiss", "yanmega", "leafeon", "glaceon", "gliscor", "mamoswine", "porygon-z", "gallade", "probopass", "dusknoir", "froslass", "rotom", "uxie", "mesprit", "azelf", "dialga", "palkia", "heatran", "regigigas", "giratina", "cresselia", "phione", "manaphy", "darkrai", "shaymin", "arceus", "victini", "snivy", "servine", "serperior", "tepig", "pignite", "emboar", "oshawott", "dewott", "samurott", "patrat", "watchog", "lillipup", "herdier", "stoutland", "purrloin", "liepard", "pansage", "simisage", "pansear", "simisear", "panpour", "simipour", "munna", "musharna", "pidove", "tranquill", "unfezant", "blitzle", "zebstrika", "roggenrola", "boldore", "gigalith", "woobat", "swoobat", "drilbur", "excadrill", "audino", "timburr", "gurdurr", "conkeldurr", "tympole", "palpitoad", "seismitoad", "throh", "sawk", "sewaddle", "swadloon", "leavanny", "venipede", "whirlipede", "scolipede", "cottonee", "whimsicott", "petilil", "lilligant", "basculin", "sandile", "krokorok", "krookodile", "darumaka", "darmanitan", "maractus", "dwebble", "crustle", "scraggy", "scrafty", "sigilyph", "yamask", "cofagrigus", "tirtouga", "carracosta", "archen", "archeops", "trubbish", "garbodor", "zorua", "zoroark", "minccino", "cinccino", "gothita", "gothorita", "gothitelle", "solosis", "duosion", "reuniclus", "ducklett", "swanna", "vanillite", "vanillish", "vanilluxe", "deerling", "sawsbuck", "emolga", "karrablast", "escavalier", "foongus", "amoonguss", "frillish", "jellicent", "alomomola", "joltik", "galvantula", "ferroseed", "ferrothorn", "klink", "klang", "klinklang", "tynamo", "eelektrik", "eelektross", "elgyem", "beheeyem", "litwick", "lampent", "chandelure", "axew", "fraxure", "haxorus", "cubchoo", "beartic", "cryogonal", "shelmet", "accelgor", "stunfisk", "mienfoo", "mienshao", "druddigon", "golett", "golurk", "pawniard", "bisharp", "bouffalant", "rufflet", "braviary", "vullaby", "mandibuzz", "heatmor", "durant", "deino", "zweilous", "hydreigon", "larvesta", "volcarona", "cobalion", "terrakion", "virizion", "tornadus", "thundurus", "reshiram", "zekrom", "landorus", "kyurem", "keldeo", "meloetta", "genesect", "chespin", "quilladin", "chesnaught", "fennekin", "braixen", "delphox", "froakie", "frogadier", "greninja", "bunnelby", "diggersby", "fletchling", "fletchinder", "talonflame", "scatterbug", "spewpa", "vivillon", "litleo", "pyroar", "flabebe", "floette", "florges", "skiddo", "gogoat", "pancham", "pangoro", "furfrou", "espurr", "meowstic", "honedge", "doublade", "aegislash", "spritzee", "aromatisse", "swirlix", "slurpuff", "inkay", "malamar", "binacle", "barbaracle", "skrelp", "dragalge", "clauncher", "clawitzer", "helioptile", "heliolisk", "tyrunt", "tyrantrum", "amaura", "aurorus", "sylveon", "hawlucha", "dedenne", "carbink", "goomy", "sliggoo", "goodra", "klefki", "phantump", "trevenant", "pumpkaboo", "gourgeist", "bergmite", "avalugg", "noibat", "noivern", "xerneas", "yveltal", "zygarde", "diancie", "hoopa", "volcanion", "rowlet", "dartrix", "decidueye", "litten", "torracat", "incineroar", "popplio", "brionne", "primarina", "pikipek", "trumbeak", "toucannon", "yungoos", "gumshoos", "grubbin", "charjabug", "vikavolt", "crabrawler", "crabominable", "oricorio", "cutiefly", "ribombee", "rockruff", "lycanroc", "wishiwashi", "mareanie", "toxapex", "mudbray", "mudsdale", "dewpider", "araquanid", "fomantis", "lurantis", "morelull", "shiinotic", "salandit", "salazzle", "stufful", "bewear", "bounsweet", "steenee", "tsareena", "comfey", "oranguru", "passimian", "wimpod", "golisopod", "sandygast", "palossand", "pyukumuku", "typenull", "silvally", "minior", "komala", "turtonator", "togedemaru", "mimikyu", "bruxish", "drampa", "dhelmise", "jangmo-o", "hakamo-o", "kommo-o", "tapukoko", "tapulele", "tapubulu", "tapufini", "cosmog", "cosmoem", "solgaleo", "lunala", "nihilego", "buzzwole", "pheromosa", "xurkitree", "celesteela", "kartana", "guzzlord", "necrozma", "magearna", "marshadow", "poipole", "naganadel", "stakataka", "blacephalon", "zeraora", "meltan", "melmetal", "grookey", "thwackey", "rillaboom", "scorbunny", "raboot", "cinderace", "sobble", "drizzile", "inteleon", "skwovet", "greedent", "rookidee", "corvisquire", "corviknight", "blipbug", "dottler", "orbeetle", "nickit", "thievul", "gossifleur", "eldegoss", "wooloo", "dubwool", "chewtle", "drednaw", "yamper", "boltund", "rolycoly", "carkol", "coalossal", "applin", "flapple", "appletun", "silicobra", "sandaconda", "cramorant", "arrokuda", "barraskewda", "toxel", "toxtricity", "sizzlipede", "centiskorch", "clobbopus", "grapploct", "sinistea", "polteageist", "hatenna", "hattrem", "hatterene", "impidimp", "morgrem", "grimmsnarl", "obstagoon", "perrserker", "cursola", "sirfetchd", "mrrime", "runerigus", "milcery", "alcremie", "falinks", "pincurchin", "snom", "frosmoth", "stonjourner", "eiscue", "indeedee", "morpeko", "cufant", "copperajah", "dracozolt", "arctozolt", "dracovish", "arctovish", "duraludon", "dreepy", "drakloak", "dragapult", "zacian", "zamazenta", "eternatus", "kubfu", "urshifu", "zarude", "regieleki", "regidrago", "glastrier", "spectrier", "calyrex"]`,
						Validators: []validator.String{
							stringvalidator.OneOf(
								"bulbasaur",
								"ivysaur",
								"venusaur",
								"charmander",
								"charmeleon",
								"charizard",
								"squirtle",
								"wartortle",
								"blastoise",
								"caterpie",
								"metapod",
								"butterfree",
								"weedle",
								"kakuna",
								"beedrill",
								"pidgey",
								"pidgeotto",
								"pidgeot",
								"rattata",
								"raticate",
								"spearow",
								"fearow",
								"ekans",
								"arbok",
								"pikachu",
								"raichu",
								"sandshrew",
								"sandslash",
								"nidoranf",
								"nidorina",
								"nidoqueen",
								"nidoranm",
								"nidorino",
								"nidoking",
								"clefairy",
								"clefable",
								"vulpix",
								"ninetales",
								"jigglypuff",
								"wigglytuff",
								"zubat",
								"golbat",
								"oddish",
								"gloom",
								"vileplume",
								"paras",
								"parasect",
								"venonat",
								"venomoth",
								"diglett",
								"dugtrio",
								"meowth",
								"persian",
								"psyduck",
								"golduck",
								"mankey",
								"primeape",
								"growlithe",
								"arcanine",
								"poliwag",
								"poliwhirl",
								"poliwrath",
								"abra",
								"kadabra",
								"alakazam",
								"machop",
								"machoke",
								"machamp",
								"bellsprout",
								"weepinbell",
								"victreebel",
								"tentacool",
								"tentacruel",
								"geodude",
								"graveler",
								"golem",
								"ponyta",
								"rapidash",
								"slowpoke",
								"slowbro",
								"magnemite",
								"magneton",
								"farfetchd",
								"doduo",
								"dodrio",
								"seel",
								"dewgong",
								"grimer",
								"muk",
								"shellder",
								"cloyster",
								"gastly",
								"haunter",
								"gengar",
								"onix",
								"drowzee",
								"hypno",
								"krabby",
								"kingler",
								"voltorb",
								"electrode",
								"exeggcute",
								"exeggutor",
								"cubone",
								"marowak",
								"hitmonlee",
								"hitmonchan",
								"lickitung",
								"koffing",
								"weezing",
								"rhyhorn",
								"rhydon",
								"chansey",
								"tangela",
								"kangaskhan",
								"horsea",
								"seadra",
								"goldeen",
								"seaking",
								"staryu",
								"starmie",
								"mrmime",
								"scyther",
								"jynx",
								"electabuzz",
								"magmar",
								"pinsir",
								"tauros",
								"magikarp",
								"gyarados",
								"lapras",
								"ditto",
								"eevee",
								"vaporeon",
								"jolteon",
								"flareon",
								"porygon",
								"omanyte",
								"omastar",
								"kabuto",
								"kabutops",
								"aerodactyl",
								"snorlax",
								"articuno",
								"zapdos",
								"moltres",
								"dratini",
								"dragonair",
								"dragonite",
								"mewtwo",
								"mew",
								"chikorita",
								"bayleef",
								"meganium",
								"cyndaquil",
								"quilava",
								"typhlosion",
								"totodile",
								"croconaw",
								"feraligatr",
								"sentret",
								"furret",
								"hoothoot",
								"noctowl",
								"ledyba",
								"ledian",
								"spinarak",
								"ariados",
								"crobat",
								"chinchou",
								"lanturn",
								"pichu",
								"cleffa",
								"igglybuff",
								"togepi",
								"togetic",
								"natu",
								"xatu",
								"mareep",
								"flaaffy",
								"ampharos",
								"bellossom",
								"marill",
								"azumarill",
								"sudowoodo",
								"politoed",
								"hoppip",
								"skiploom",
								"jumpluff",
								"aipom",
								"sunkern",
								"sunflora",
								"yanma",
								"wooper",
								"quagsire",
								"espeon",
								"umbreon",
								"murkrow",
								"slowking",
								"misdreavus",
								"unown",
								"wobbuffet",
								"girafarig",
								"pineco",
								"forretress",
								"dunsparce",
								"gligar",
								"steelix",
								"snubbull",
								"granbull",
								"qwilfish",
								"scizor",
								"shuckle",
								"heracross",
								"sneasel",
								"teddiursa",
								"ursaring",
								"slugma",
								"magcargo",
								"swinub",
								"piloswine",
								"corsola",
								"remoraid",
								"octillery",
								"delibird",
								"mantine",
								"skarmory",
								"houndour",
								"houndoom",
								"kingdra",
								"phanpy",
								"donphan",
								"porygon2",
								"stantler",
								"smeargle",
								"tyrogue",
								"hitmontop",
								"smoochum",
								"elekid",
								"magby",
								"miltank",
								"blissey",
								"raikou",
								"entei",
								"suicune",
								"larvitar",
								"pupitar",
								"tyranitar",
								"lugia",
								"ho-oh",
								"celebi",
								"treecko",
								"grovyle",
								"sceptile",
								"torchic",
								"combusken",
								"blaziken",
								"mudkip",
								"marshtomp",
								"swampert",
								"poochyena",
								"mightyena",
								"zigzagoon",
								"linoone",
								"wurmple",
								"silcoon",
								"beautifly",
								"cascoon",
								"dustox",
								"lotad",
								"lombre",
								"ludicolo",
								"seedot",
								"nuzleaf",
								"shiftry",
								"taillow",
								"swellow",
								"wingull",
								"pelipper",
								"ralts",
								"kirlia",
								"gardevoir",
								"surskit",
								"masquerain",
								"shroomish",
								"breloom",
								"slakoth",
								"vigoroth",
								"slaking",
								"nincada",
								"ninjask",
								"shedinja",
								"whismur",
								"loudred",
								"exploud",
								"makuhita",
								"hariyama",
								"azurill",
								"nosepass",
								"skitty",
								"delcatty",
								"sableye",
								"mawile",
								"aron",
								"lairon",
								"aggron",
								"meditite",
								"medicham",
								"electrike",
								"manectric",
								"plusle",
								"minun",
								"volbeat",
								"illumise",
								"roselia",
								"gulpin",
								"swalot",
								"carvanha",
								"sharpedo",
								"wailmer",
								"wailord",
								"numel",
								"camerupt",
								"torkoal",
								"spoink",
								"grumpig",
								"spinda",
								"trapinch",
								"vibrava",
								"flygon",
								"cacnea",
								"cacturne",
								"swablu",
								"altaria",
								"zangoose",
								"seviper",
								"lunatone",
								"solrock",
								"barboach",
								"whiscash",
								"corphish",
								"crawdaunt",
								"baltoy",
								"claydol",
								"lileep",
								"cradily",
								"anorith",
								"armaldo",
								"feebas",
								"milotic",
								"castform",
								"kecleon",
								"shuppet",
								"banette",
								"duskull",
								"dusclops",
								"tropius",
								"chimecho",
								"absol",
								"wynaut",
								"snorunt",
								"glalie",
								"spheal",
								"sealeo",
								"walrein",
								"clamperl",
								"huntail",
								"gorebyss",
								"relicanth",
								"luvdisc",
								"bagon",
								"shelgon",
								"salamence",
								"beldum",
								"metang",
								"metagross",
								"regirock",
								"regice",
								"registeel",
								"latias",
								"latios",
								"kyogre",
								"groudon",
								"rayquaza",
								"jirachi",
								"deoxys",
								"turtwig",
								"grotle",
								"torterra",
								"chimchar",
								"monferno",
								"infernape",
								"piplup",
								"prinplup",
								"empoleon",
								"starly",
								"staravia",
								"staraptor",
								"bidoof",
								"bibarel",
								"kricketot",
								"kricketune",
								"shinx",
								"luxio",
								"luxray",
								"budew",
								"roserade",
								"cranidos",
								"rampardos",
								"shieldon",
								"bastiodon",
								"burmy",
								"wormadam",
								"mothim",
								"combee",
								"vespiquen",
								"pachirisu",
								"buizel",
								"floatzel",
								"cherubi",
								"cherrim",
								"shellos",
								"gastrodon",
								"ambipom",
								"drifloon",
								"drifblim",
								"buneary",
								"lopunny",
								"mismagius",
								"honchkrow",
								"glameow",
								"purugly",
								"chingling",
								"stunky",
								"skuntank",
								"bronzor",
								"bronzong",
								"bonsly",
								"mimejr",
								"happiny",
								"chatot",
								"spiritomb",
								"gible",
								"gabite",
								"garchomp",
								"munchlax",
								"riolu",
								"lucario",
								"hippopotas",
								"hippowdon",
								"skorupi",
								"drapion",
								"croagunk",
								"toxicroak",
								"carnivine",
								"finneon",
								"lumineon",
								"mantyke",
								"snover",
								"abomasnow",
								"weavile",
								"magnezone",
								"lickilicky",
								"rhyperior",
								"tangrowth",
								"electivire",
								"magmortar",
								"togekiss",
								"yanmega",
								"leafeon",
								"glaceon",
								"gliscor",
								"mamoswine",
								"porygon-z",
								"gallade",
								"probopass",
								"dusknoir",
								"froslass",
								"rotom",
								"uxie",
								"mesprit",
								"azelf",
								"dialga",
								"palkia",
								"heatran",
								"regigigas",
								"giratina",
								"cresselia",
								"phione",
								"manaphy",
								"darkrai",
								"shaymin",
								"arceus",
								"victini",
								"snivy",
								"servine",
								"serperior",
								"tepig",
								"pignite",
								"emboar",
								"oshawott",
								"dewott",
								"samurott",
								"patrat",
								"watchog",
								"lillipup",
								"herdier",
								"stoutland",
								"purrloin",
								"liepard",
								"pansage",
								"simisage",
								"pansear",
								"simisear",
								"panpour",
								"simipour",
								"munna",
								"musharna",
								"pidove",
								"tranquill",
								"unfezant",
								"blitzle",
								"zebstrika",
								"roggenrola",
								"boldore",
								"gigalith",
								"woobat",
								"swoobat",
								"drilbur",
								"excadrill",
								"audino",
								"timburr",
								"gurdurr",
								"conkeldurr",
								"tympole",
								"palpitoad",
								"seismitoad",
								"throh",
								"sawk",
								"sewaddle",
								"swadloon",
								"leavanny",
								"venipede",
								"whirlipede",
								"scolipede",
								"cottonee",
								"whimsicott",
								"petilil",
								"lilligant",
								"basculin",
								"sandile",
								"krokorok",
								"krookodile",
								"darumaka",
								"darmanitan",
								"maractus",
								"dwebble",
								"crustle",
								"scraggy",
								"scrafty",
								"sigilyph",
								"yamask",
								"cofagrigus",
								"tirtouga",
								"carracosta",
								"archen",
								"archeops",
								"trubbish",
								"garbodor",
								"zorua",
								"zoroark",
								"minccino",
								"cinccino",
								"gothita",
								"gothorita",
								"gothitelle",
								"solosis",
								"duosion",
								"reuniclus",
								"ducklett",
								"swanna",
								"vanillite",
								"vanillish",
								"vanilluxe",
								"deerling",
								"sawsbuck",
								"emolga",
								"karrablast",
								"escavalier",
								"foongus",
								"amoonguss",
								"frillish",
								"jellicent",
								"alomomola",
								"joltik",
								"galvantula",
								"ferroseed",
								"ferrothorn",
								"klink",
								"klang",
								"klinklang",
								"tynamo",
								"eelektrik",
								"eelektross",
								"elgyem",
								"beheeyem",
								"litwick",
								"lampent",
								"chandelure",
								"axew",
								"fraxure",
								"haxorus",
								"cubchoo",
								"beartic",
								"cryogonal",
								"shelmet",
								"accelgor",
								"stunfisk",
								"mienfoo",
								"mienshao",
								"druddigon",
								"golett",
								"golurk",
								"pawniard",
								"bisharp",
								"bouffalant",
								"rufflet",
								"braviary",
								"vullaby",
								"mandibuzz",
								"heatmor",
								"durant",
								"deino",
								"zweilous",
								"hydreigon",
								"larvesta",
								"volcarona",
								"cobalion",
								"terrakion",
								"virizion",
								"tornadus",
								"thundurus",
								"reshiram",
								"zekrom",
								"landorus",
								"kyurem",
								"keldeo",
								"meloetta",
								"genesect",
								"chespin",
								"quilladin",
								"chesnaught",
								"fennekin",
								"braixen",
								"delphox",
								"froakie",
								"frogadier",
								"greninja",
								"bunnelby",
								"diggersby",
								"fletchling",
								"fletchinder",
								"talonflame",
								"scatterbug",
								"spewpa",
								"vivillon",
								"litleo",
								"pyroar",
								"flabebe",
								"floette",
								"florges",
								"skiddo",
								"gogoat",
								"pancham",
								"pangoro",
								"furfrou",
								"espurr",
								"meowstic",
								"honedge",
								"doublade",
								"aegislash",
								"spritzee",
								"aromatisse",
								"swirlix",
								"slurpuff",
								"inkay",
								"malamar",
								"binacle",
								"barbaracle",
								"skrelp",
								"dragalge",
								"clauncher",
								"clawitzer",
								"helioptile",
								"heliolisk",
								"tyrunt",
								"tyrantrum",
								"amaura",
								"aurorus",
								"sylveon",
								"hawlucha",
								"dedenne",
								"carbink",
								"goomy",
								"sliggoo",
								"goodra",
								"klefki",
								"phantump",
								"trevenant",
								"pumpkaboo",
								"gourgeist",
								"bergmite",
								"avalugg",
								"noibat",
								"noivern",
								"xerneas",
								"yveltal",
								"zygarde",
								"diancie",
								"hoopa",
								"volcanion",
								"rowlet",
								"dartrix",
								"decidueye",
								"litten",
								"torracat",
								"incineroar",
								"popplio",
								"brionne",
								"primarina",
								"pikipek",
								"trumbeak",
								"toucannon",
								"yungoos",
								"gumshoos",
								"grubbin",
								"charjabug",
								"vikavolt",
								"crabrawler",
								"crabominable",
								"oricorio",
								"cutiefly",
								"ribombee",
								"rockruff",
								"lycanroc",
								"wishiwashi",
								"mareanie",
								"toxapex",
								"mudbray",
								"mudsdale",
								"dewpider",
								"araquanid",
								"fomantis",
								"lurantis",
								"morelull",
								"shiinotic",
								"salandit",
								"salazzle",
								"stufful",
								"bewear",
								"bounsweet",
								"steenee",
								"tsareena",
								"comfey",
								"oranguru",
								"passimian",
								"wimpod",
								"golisopod",
								"sandygast",
								"palossand",
								"pyukumuku",
								"typenull",
								"silvally",
								"minior",
								"komala",
								"turtonator",
								"togedemaru",
								"mimikyu",
								"bruxish",
								"drampa",
								"dhelmise",
								"jangmo-o",
								"hakamo-o",
								"kommo-o",
								"tapukoko",
								"tapulele",
								"tapubulu",
								"tapufini",
								"cosmog",
								"cosmoem",
								"solgaleo",
								"lunala",
								"nihilego",
								"buzzwole",
								"pheromosa",
								"xurkitree",
								"celesteela",
								"kartana",
								"guzzlord",
								"necrozma",
								"magearna",
								"marshadow",
								"poipole",
								"naganadel",
								"stakataka",
								"blacephalon",
								"zeraora",
								"meltan",
								"melmetal",
								"grookey",
								"thwackey",
								"rillaboom",
								"scorbunny",
								"raboot",
								"cinderace",
								"sobble",
								"drizzile",
								"inteleon",
								"skwovet",
								"greedent",
								"rookidee",
								"corvisquire",
								"corviknight",
								"blipbug",
								"dottler",
								"orbeetle",
								"nickit",
								"thievul",
								"gossifleur",
								"eldegoss",
								"wooloo",
								"dubwool",
								"chewtle",
								"drednaw",
								"yamper",
								"boltund",
								"rolycoly",
								"carkol",
								"coalossal",
								"applin",
								"flapple",
								"appletun",
								"silicobra",
								"sandaconda",
								"cramorant",
								"arrokuda",
								"barraskewda",
								"toxel",
								"toxtricity",
								"sizzlipede",
								"centiskorch",
								"clobbopus",
								"grapploct",
								"sinistea",
								"polteageist",
								"hatenna",
								"hattrem",
								"hatterene",
								"impidimp",
								"morgrem",
								"grimmsnarl",
								"obstagoon",
								"perrserker",
								"cursola",
								"sirfetchd",
								"mrrime",
								"runerigus",
								"milcery",
								"alcremie",
								"falinks",
								"pincurchin",
								"snom",
								"frosmoth",
								"stonjourner",
								"eiscue",
								"indeedee",
								"morpeko",
								"cufant",
								"copperajah",
								"dracozolt",
								"arctozolt",
								"dracovish",
								"arctovish",
								"duraludon",
								"dreepy",
								"drakloak",
								"dragapult",
								"zacian",
								"zamazenta",
								"eternatus",
								"kubfu",
								"urshifu",
								"zarude",
								"regieleki",
								"regidrago",
								"glastrier",
								"spectrier",
								"calyrex",
							),
						},
					},
				},
			},
			"created_at": schema.Int64Attribute{
				Computed: true,
				PlanModifiers: []planmodifier.Int64{
					speakeasy_int64planmodifier.SuppressDiff(speakeasy_int64planmodifier.ExplicitSuppress),
				},
			},
			"definition_id": schema.StringAttribute{
				Computed: true,
				Optional: true,
				PlanModifiers: []planmodifier.String{
					stringplanmodifier.RequiresReplaceIfConfigured(),
					speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
				},
				Description: `The UUID of the connector definition. One of configuration.sourceType or definitionId must be provided. Requires replacement if changed.`,
			},
			"name": schema.StringAttribute{
				Required: true,
				PlanModifiers: []planmodifier.String{
					speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
				},
				Description: `Name of the source e.g. dev-mysql-instance.`,
			},
			"resource_allocation": schema.SingleNestedAttribute{
				Computed: true,
				PlanModifiers: []planmodifier.Object{
					speakeasy_objectplanmodifier.SuppressDiff(speakeasy_objectplanmodifier.ExplicitSuppress),
				},
				Attributes: map[string]schema.Attribute{
					"default": schema.SingleNestedAttribute{
						Computed: true,
						PlanModifiers: []planmodifier.Object{
							speakeasy_objectplanmodifier.SuppressDiff(speakeasy_objectplanmodifier.ExplicitSuppress),
						},
						Attributes: map[string]schema.Attribute{
							"cpu_limit": schema.StringAttribute{
								Computed: true,
								PlanModifiers: []planmodifier.String{
									speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
								},
							},
							"cpu_request": schema.StringAttribute{
								Computed: true,
								PlanModifiers: []planmodifier.String{
									speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
								},
							},
							"ephemeral_storage_limit": schema.StringAttribute{
								Computed: true,
								PlanModifiers: []planmodifier.String{
									speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
								},
							},
							"ephemeral_storage_request": schema.StringAttribute{
								Computed: true,
								PlanModifiers: []planmodifier.String{
									speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
								},
							},
							"memory_limit": schema.StringAttribute{
								Computed: true,
								PlanModifiers: []planmodifier.String{
									speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
								},
							},
							"memory_request": schema.StringAttribute{
								Computed: true,
								PlanModifiers: []planmodifier.String{
									speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
								},
							},
						},
						Description: `optional resource requirements to run workers (blank for unbounded allocations)`,
					},
					"job_specific": schema.ListNestedAttribute{
						Computed: true,
						PlanModifiers: []planmodifier.List{
							speakeasy_listplanmodifier.SuppressDiff(speakeasy_listplanmodifier.ExplicitSuppress),
						},
						NestedObject: schema.NestedAttributeObject{
							PlanModifiers: []planmodifier.Object{
								speakeasy_objectplanmodifier.SuppressDiff(speakeasy_objectplanmodifier.ExplicitSuppress),
							},
							Attributes: map[string]schema.Attribute{
								"job_type": schema.StringAttribute{
									Computed: true,
									PlanModifiers: []planmodifier.String{
										speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
									},
									Description: `enum that describes the different types of jobs that the platform runs. must be one of ["get_spec", "check_connection", "discover_schema", "sync", "reset_connection", "connection_updater", "replicate"]`,
									Validators: []validator.String{
										stringvalidator.OneOf(
											"get_spec",
											"check_connection",
											"discover_schema",
											"sync",
											"reset_connection",
											"connection_updater",
											"replicate",
										),
									},
								},
								"resource_requirements": schema.SingleNestedAttribute{
									Computed: true,
									PlanModifiers: []planmodifier.Object{
										speakeasy_objectplanmodifier.SuppressDiff(speakeasy_objectplanmodifier.ExplicitSuppress),
									},
									Attributes: map[string]schema.Attribute{
										"cpu_limit": schema.StringAttribute{
											Computed: true,
											PlanModifiers: []planmodifier.String{
												speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
											},
										},
										"cpu_request": schema.StringAttribute{
											Computed: true,
											PlanModifiers: []planmodifier.String{
												speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
											},
										},
										"ephemeral_storage_limit": schema.StringAttribute{
											Computed: true,
											PlanModifiers: []planmodifier.String{
												speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
											},
										},
										"ephemeral_storage_request": schema.StringAttribute{
											Computed: true,
											PlanModifiers: []planmodifier.String{
												speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
											},
										},
										"memory_limit": schema.StringAttribute{
											Computed: true,
											PlanModifiers: []planmodifier.String{
												speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
											},
										},
										"memory_request": schema.StringAttribute{
											Computed: true,
											PlanModifiers: []planmodifier.String{
												speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
											},
										},
									},
									Description: `optional resource requirements to run workers (blank for unbounded allocations)`,
								},
							},
						},
					},
				},
				Description: `actor or actor definition specific resource requirements. if default is set, these are the requirements that should be set for ALL jobs run for this actor definition. it is overriden by the job type specific configurations. if not set, the platform will use defaults. these values will be overriden by configuration at the connection level.`,
			},
			"secret_id": schema.StringAttribute{
				Optional: true,
				PlanModifiers: []planmodifier.String{
					stringplanmodifier.RequiresReplaceIfConfigured(),
				},
				Description: `Optional secretID obtained through the public API OAuth redirect flow. Requires replacement if changed.`,
			},
			"source_id": schema.StringAttribute{
				Computed: true,
				PlanModifiers: []planmodifier.String{
					speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
				},
			},
			"source_type": schema.StringAttribute{
				Computed: true,
				PlanModifiers: []planmodifier.String{
					speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
				},
			},
			"workspace_id": schema.StringAttribute{
				Required: true,
				PlanModifiers: []planmodifier.String{
					speakeasy_stringplanmodifier.SuppressDiff(speakeasy_stringplanmodifier.ExplicitSuppress),
				},
			},
		},
	}
}

func (r *SourcePokeapiResource) Configure(ctx context.Context, req resource.ConfigureRequest, resp *resource.ConfigureResponse) {
	// Prevent panic if the provider has not been configured.
	if req.ProviderData == nil {
		return
	}

	client, ok := req.ProviderData.(*sdk.SDK)

	if !ok {
		resp.Diagnostics.AddError(
			"Unexpected Resource Configure Type",
			fmt.Sprintf("Expected *sdk.SDK, got: %T. Please report this issue to the provider developers.", req.ProviderData),
		)

		return
	}

	r.client = client
}

func (r *SourcePokeapiResource) Create(ctx context.Context, req resource.CreateRequest, resp *resource.CreateResponse) {
	var data *SourcePokeapiResourceModel
	var plan types.Object

	resp.Diagnostics.Append(req.Plan.Get(ctx, &plan)...)
	if resp.Diagnostics.HasError() {
		return
	}

	resp.Diagnostics.Append(plan.As(ctx, &data, basetypes.ObjectAsOptions{
		UnhandledNullAsEmpty:    true,
		UnhandledUnknownAsEmpty: true,
	})...)

	if resp.Diagnostics.HasError() {
		return
	}

	request := data.ToSharedSourcePokeapiCreateRequest()
	res, err := r.client.Sources.CreateSourcePokeapi(ctx, request)
	if err != nil {
		resp.Diagnostics.AddError("failure to invoke API", err.Error())
		if res != nil && res.RawResponse != nil {
			resp.Diagnostics.AddError("unexpected http request/response", debugResponse(res.RawResponse))
		}
		return
	}
	if res == nil {
		resp.Diagnostics.AddError("unexpected response from API", fmt.Sprintf("%v", res))
		return
	}
	if res.StatusCode != 200 {
		resp.Diagnostics.AddError(fmt.Sprintf("unexpected response from API. Got an unexpected response code %v", res.StatusCode), debugResponse(res.RawResponse))
		return
	}
	if !(res.SourceResponse != nil) {
		resp.Diagnostics.AddError("unexpected response from API. Got an unexpected response body", debugResponse(res.RawResponse))
		return
	}
	data.RefreshFromSharedSourceResponse(res.SourceResponse)
	refreshPlan(ctx, plan, &data, resp.Diagnostics)
	var sourceID string
	sourceID = data.SourceID.ValueString()

	request1 := operations.GetSourcePokeapiRequest{
		SourceID: sourceID,
	}
	res1, err := r.client.Sources.GetSourcePokeapi(ctx, request1)
	if err != nil {
		resp.Diagnostics.AddError("failure to invoke API", err.Error())
		if res1 != nil && res1.RawResponse != nil {
			resp.Diagnostics.AddError("unexpected http request/response", debugResponse(res1.RawResponse))
		}
		return
	}
	if res1 == nil {
		resp.Diagnostics.AddError("unexpected response from API", fmt.Sprintf("%v", res1))
		return
	}
	if res1.StatusCode != 200 {
		resp.Diagnostics.AddError(fmt.Sprintf("unexpected response from API. Got an unexpected response code %v", res1.StatusCode), debugResponse(res1.RawResponse))
		return
	}
	if !(res1.SourceResponse != nil) {
		resp.Diagnostics.AddError("unexpected response from API. Got an unexpected response body", debugResponse(res1.RawResponse))
		return
	}
	data.RefreshFromSharedSourceResponse(res1.SourceResponse)
	refreshPlan(ctx, plan, &data, resp.Diagnostics)

	// Save updated data into Terraform state
	resp.Diagnostics.Append(resp.State.Set(ctx, &data)...)
}

func (r *SourcePokeapiResource) Read(ctx context.Context, req resource.ReadRequest, resp *resource.ReadResponse) {
	var data *SourcePokeapiResourceModel
	var item types.Object

	resp.Diagnostics.Append(req.State.Get(ctx, &item)...)
	if resp.Diagnostics.HasError() {
		return
	}

	resp.Diagnostics.Append(item.As(ctx, &data, basetypes.ObjectAsOptions{
		UnhandledNullAsEmpty:    true,
		UnhandledUnknownAsEmpty: true,
	})...)

	if resp.Diagnostics.HasError() {
		return
	}

	var sourceID string
	sourceID = data.SourceID.ValueString()

	request := operations.GetSourcePokeapiRequest{
		SourceID: sourceID,
	}
	res, err := r.client.Sources.GetSourcePokeapi(ctx, request)
	if err != nil {
		resp.Diagnostics.AddError("failure to invoke API", err.Error())
		if res != nil && res.RawResponse != nil {
			resp.Diagnostics.AddError("unexpected http request/response", debugResponse(res.RawResponse))
		}
		return
	}
	if res == nil {
		resp.Diagnostics.AddError("unexpected response from API", fmt.Sprintf("%v", res))
		return
	}
	if res.StatusCode == 404 {
		resp.State.RemoveResource(ctx)
		return
	}
	if res.StatusCode != 200 {
		resp.Diagnostics.AddError(fmt.Sprintf("unexpected response from API. Got an unexpected response code %v", res.StatusCode), debugResponse(res.RawResponse))
		return
	}
	if !(res.SourceResponse != nil) {
		resp.Diagnostics.AddError("unexpected response from API. Got an unexpected response body", debugResponse(res.RawResponse))
		return
	}
	data.RefreshFromSharedSourceResponse(res.SourceResponse)

	// Save updated data into Terraform state
	resp.Diagnostics.Append(resp.State.Set(ctx, &data)...)
}

func (r *SourcePokeapiResource) Update(ctx context.Context, req resource.UpdateRequest, resp *resource.UpdateResponse) {
	var data *SourcePokeapiResourceModel
	var plan types.Object

	resp.Diagnostics.Append(req.Plan.Get(ctx, &plan)...)
	if resp.Diagnostics.HasError() {
		return
	}

	merge(ctx, req, resp, &data)
	if resp.Diagnostics.HasError() {
		return
	}

	var sourceID string
	sourceID = data.SourceID.ValueString()

	sourcePokeapiPutRequest := data.ToSharedSourcePokeapiPutRequest()
	request := operations.PutSourcePokeapiRequest{
		SourceID:                sourceID,
		SourcePokeapiPutRequest: sourcePokeapiPutRequest,
	}
	res, err := r.client.Sources.PutSourcePokeapi(ctx, request)
	if err != nil {
		resp.Diagnostics.AddError("failure to invoke API", err.Error())
		if res != nil && res.RawResponse != nil {
			resp.Diagnostics.AddError("unexpected http request/response", debugResponse(res.RawResponse))
		}
		return
	}
	if res == nil {
		resp.Diagnostics.AddError("unexpected response from API", fmt.Sprintf("%v", res))
		return
	}
	if fmt.Sprintf("%v", res.StatusCode)[0] != '2' {
		resp.Diagnostics.AddError(fmt.Sprintf("unexpected response from API. Got an unexpected response code %v", res.StatusCode), debugResponse(res.RawResponse))
		return
	}
	refreshPlan(ctx, plan, &data, resp.Diagnostics)
	var sourceId1 string
	sourceId1 = data.SourceID.ValueString()

	request1 := operations.GetSourcePokeapiRequest{
		SourceID: sourceId1,
	}
	res1, err := r.client.Sources.GetSourcePokeapi(ctx, request1)
	if err != nil {
		resp.Diagnostics.AddError("failure to invoke API", err.Error())
		if res1 != nil && res1.RawResponse != nil {
			resp.Diagnostics.AddError("unexpected http request/response", debugResponse(res1.RawResponse))
		}
		return
	}
	if res1 == nil {
		resp.Diagnostics.AddError("unexpected response from API", fmt.Sprintf("%v", res1))
		return
	}
	if res1.StatusCode != 200 {
		resp.Diagnostics.AddError(fmt.Sprintf("unexpected response from API. Got an unexpected response code %v", res1.StatusCode), debugResponse(res1.RawResponse))
		return
	}
	if !(res1.SourceResponse != nil) {
		resp.Diagnostics.AddError("unexpected response from API. Got an unexpected response body", debugResponse(res1.RawResponse))
		return
	}
	data.RefreshFromSharedSourceResponse(res1.SourceResponse)
	refreshPlan(ctx, plan, &data, resp.Diagnostics)

	// Save updated data into Terraform state
	resp.Diagnostics.Append(resp.State.Set(ctx, &data)...)
}

func (r *SourcePokeapiResource) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse) {
	var data *SourcePokeapiResourceModel
	var item types.Object

	resp.Diagnostics.Append(req.State.Get(ctx, &item)...)
	if resp.Diagnostics.HasError() {
		return
	}

	resp.Diagnostics.Append(item.As(ctx, &data, basetypes.ObjectAsOptions{
		UnhandledNullAsEmpty:    true,
		UnhandledUnknownAsEmpty: true,
	})...)

	if resp.Diagnostics.HasError() {
		return
	}

	var sourceID string
	sourceID = data.SourceID.ValueString()

	request := operations.DeleteSourcePokeapiRequest{
		SourceID: sourceID,
	}
	res, err := r.client.Sources.DeleteSourcePokeapi(ctx, request)
	if err != nil {
		resp.Diagnostics.AddError("failure to invoke API", err.Error())
		if res != nil && res.RawResponse != nil {
			resp.Diagnostics.AddError("unexpected http request/response", debugResponse(res.RawResponse))
		}
		return
	}
	if res == nil {
		resp.Diagnostics.AddError("unexpected response from API", fmt.Sprintf("%v", res))
		return
	}
	if fmt.Sprintf("%v", res.StatusCode)[0] != '2' {
		resp.Diagnostics.AddError(fmt.Sprintf("unexpected response from API. Got an unexpected response code %v", res.StatusCode), debugResponse(res.RawResponse))
		return
	}

}

func (r *SourcePokeapiResource) ImportState(ctx context.Context, req resource.ImportStateRequest, resp *resource.ImportStateResponse) {
	resp.Diagnostics.Append(resp.State.SetAttribute(ctx, path.Root("source_id"), req.ID)...)
}
