![]() |
GPAL - Generally Positive Automation Library v1.0
GPAL The Fluent Automation LIbrary
|
Fluent REST client for making API calls with a chained interface. Supports defining workflows, executing them in loops, and accessing results. Results are accessed via a non-generic indexer, requiring casting to the desired type. More...
Public Member Functions | |
| IAllowRESTEndpointDetails | WithAPIBase (string url) |
| Sets the API base URL with download path. | |
| IAllowRESTEndpointDetails | WithAPIBase (string url, TimeSpan httpTimeout) |
| Sets the API base URL and how long one attempt is given before it is abandoned. | |
| IAllowRESTParametersOrExecution | WithEndpoint (string endpoint) |
| Sets the endpoint as a string. | |
| IAllowRESTParametersOrExecution | WithEndpoint (ApiEndpoint endpoint) |
| Sets the endpoint from an ApiEndpoint enum. | |
| IAllowRESTEndpointDetails | LoadOpenAPIMap (string yamlOrUrl) |
| IAllowRESTEndpointDetails | LoadOpenAPIMap (GPALFile openApiMapFile) |
| void | LoadOpenApiRulesInternal (string yamlContent) |
| IAllowRESTEndpointDetails | ListOpenAPIEndPoints () |
| IAllowRESTParametersOrExecution | WithResultName (string name) |
| Sets the result name for the next execution. | |
| IAllowRESTParametersOrExecution | WithUrl (string url) |
| Sets the URL parameter. | |
| IAllowRESTParametersOrExecution | WithUrlFromResult (int resultIndex) |
| Sets the URL from a result by index. | |
| IAllowRESTParametersOrExecution | WithUrlFromResult (string name) |
| Sets the URL from a result by name. | |
| IAllowRESTParametersOrExecution | WithTabId (int tabId) |
| Sets the tab ID parameter. | |
| IAllowRESTParametersOrExecution | WithTabIdFromResult (int resultIndex) |
| Sets the tab ID from a result by index. | |
| IAllowRESTParametersOrExecution | WithTabIdFromResult (string name) |
| Sets the tab ID from a result by name. | |
| IAllowRESTParametersOrExecution | WithScript (string script) |
| Sets the script parameter. | |
| IAllowRESTParametersOrExecution | WithKey (string key) |
| Sets the key parameter. | |
| IAllowRESTParametersOrExecution | WithKeyFromResult (int resultIndex) |
| Sets the key from a result by index. | |
| IAllowRESTParametersOrExecution | WithKeyFromResult (string name) |
| Sets the key from a result by name. | |
| IAllowRESTEndpointDetails | WithName (string name) |
| Sets the client name. | |
| IAllowRESTParametersOrExecution | WithCss (string css) |
| Sets the CSS parameter. | |
| IAllowRESTParametersOrExecution | WithCssFromResult (int resultIndex) |
| Sets the CSS from a result by index. | |
| IAllowRESTParametersOrExecution | WithCssFromResult (string name) |
| Sets the CSS from a result by name. | |
| IAllowRESTParametersOrExecution | WithElement (IGPALElement gPALElement) |
| Sets the element parameter. | |
| IAllowRESTParametersOrExecution | WithElementIdFromResult (int resultIndex) |
| Sets the element from a result by index. | |
| IAllowRESTParametersOrExecution | WithElementIdFromResult (string name) |
| Sets the element from a result by name. | |
| IAllowCheckNetworkIdleOrExecution | WithTimeoutMs (int timeoutMs) |
| Sets the timeout in milliseconds. | |
| IAllowCheckNetworkIdleOrExecution | WithPruneMs (int pruneMs) |
| Sets the prune interval in milliseconds. | |
| IAllowCheckNetworkIdleOrExecution | WithMaxConnections (int maxConnections) |
| Sets the maximum connections. | |
| IAllowRESTExecution | WithUploadFile (string uploadPath) |
| Sets the timeout in milliseconds. | |
| IAllowRESTExecution | WithUploadFiles (GPALFile uploadPaths) |
| Sets the timeout in milliseconds. | |
| IAllowRESTParametersOrExecution | WithXPath (string xpath) |
| Sets the XPath parameter. | |
| IAllowRESTParametersOrExecution | WithXPathFromResult (int resultIndex) |
| Sets the XPath from a result by index. | |
| IAllowRESTParametersOrExecution | WithXPathFromResult (string name) |
| Sets the XPath from a result by name. | |
| IAllowRESTParametersOrExecution | WithParameters (params object[] parameters) |
| Sets parameters as a variable argument list. | |
| IAllowRESTParametersOrExecution | WithParameters (object parameters) |
| Sets parameters as a single object. | |
| IAllowRESTParametersOrExecution | WithParametersFromResult (int resultIndex) |
| Sets parameters from a result by index. | |
| IAllowRESTParametersOrExecution | WithParametersFromResult (string name) |
| Sets parameters from a result by name. | |
| IAllowRESTStorageOptions | WithData (string data) |
| Sets the set storage data parameter. | |
| IAllowRESTStorageOptions | WithStorageStoreName (string storeName) |
| Sets the storage domain parameter. | |
| IAllowRESTStorageOptions | WithStorageDomain (string domain) |
| Sets the storage domain parameter. | |
| IAllowRESTStorageOptions | WithStoragePath (string path) |
| Sets the storage path parameter. | |
| IAllowRESTStorageOptions | WithStorageType (WebsiteStorageType storageType) |
| Sets the storage path parameter. | |
| IAllowRESTStorageOptions | WithStorageKey (string key) |
| Sets the storage key parameter. | |
| IAllowRESTStorageOptions | WithDeleteAcrossOrigins (bool crossOrigin) |
| IAllowRESTParametersOrExecution | WithPixels (int pixels) |
| Sets the pixels parameter. | |
| IAllowRESTParametersOrExecution | WithPixelsFromResult (int resultIndex) |
| Sets the pixels from a result by index. | |
| IAllowRESTParametersOrExecution | WithPixelsFromResult (string name) |
| Sets the pixels from a result by name. | |
| IAllowRESTParametersOrExecution | WithReferrer (string url) |
| Sets the referrer parameter. | |
| IAllowRESTParametersOrExecution | WithReferrerFromResult (int resultIndex) |
| Sets the referrer from a result by index. | |
| IAllowRESTParametersOrExecution | WithReferrerFromResult (string name) |
| Sets the referrer from a result by name. | |
| IAllowRESTExecution | WithText (string text) |
| Sets the text parameter. | |
| IAllowRESTExecution | WithTextFromResult (int resultIndex) |
| Sets the text from a result by index. | |
| IAllowRESTExecution | WithTextFromResult (string name) |
| Sets the text from a result by name. | |
| IAllowRESTParametersOrExecution | DownloadTo (GPALFile downloadPath) |
| Where a file the browser downloads should end up. Not SaveTo, which is GPAL writing a file it already has. This is a request the browser carries out, and what it can honor differs by engine: the extension names the download but cannot place it, so the file arrives in the browser's own download directory and the download watcher moves it here. client.WithEndpoint(ApiEndpoint.LeftClickAndDownload).DownloadTo(file).Execute();. | |
| IAllowRESTParametersOrExecution | SaveResultsTo (GPALFile file) |
| Saves the response to a file if the endpoint returns a downloadable content client.WithEndpoint(ApiEndpoint.LeftClickAndDownload).SaveResultsTo(file).Execute();. | |
| IAllowRESTExecution | WithHttpMethod (string method) |
| Sets the HTTP method. | |
| IAllowRESTAttribute | WithIndex (int index) |
| Specifies the option index for select menu operations client.SetAttribute("element123").WithAttribute("disabled").WithValue("true").Execute();. | |
| IAllowRESTExecution | WithDeviceName (string sinkName) |
| Sets the CSS parameter. | |
| string | Execute (bool publishEvent=true) |
| Executes the request synchronously. | |
| T | Execute< T > (bool publishEvent=true) |
| Executes the request synchronously with type. | |
| IRESTClient | AndThen (bool publishEvent=true) |
| Executes and chains the request. | |
| IRESTClient | AndThen< T > (bool publishEvent=true) |
| Executes and chains the request with type. | |
| async Task< string > | ExecuteAsync (bool publishEvent=true) |
| Executes the request asynchronously and returns the raw response await client.ExecuteAsync();. | |
| async Task< T > | ExecuteAsync< T > (bool publishEvent=true) |
| Executes the request asynchronously with type. | |
| IRESTClient | ToGPALObject () |
| Converts the client to a GPAL object. | |
| IAllowRESTWorkflow | ClearWorkflows () |
| Gets the execution results. | |
| IAllowRESTExecution | ClearResults () |
Empties what WithResultName has stored, so GetExecutionResults answers about what has happened since rather than everything since the client was made. | |
| ResultCollection | GetExecutionResults () |
| IReadOnlyList< object > | GetExecutionResults (string name) |
| Every result stored under name , in the order it was stored, so a loop that ran five times answers with five. Ask without a name for the whole collection, or index it by name for the last answer alone. | |
| IAllowRESTWorkflow | WithWorkflow (Action< RESTClient > workflow) |
| Adds a workflow definition client.WithWorkflow(c => c.WithEndpoint(...).Execute()).While(...);. | |
| IAllowRESTParametersOrExecution | While (Func< bool > condition) |
| Executes workflows while condition holds client.While(() => someCondition).Execute();. | |
| IAllowRESTParametersOrExecution | Until (Func< bool > condition) |
| Executes workflows until condition holds. | |
| IAllowRESTParametersOrExecution | WithElementId (string elementId) |
| Sets the element ID parameter. | |
| IAllowRESTParametersOrExecution | WithEncoding (ContentEncoding encoding) |
| Specifiy the encoiding type for posted parameters: json or urlencoded. | |
| IAllowRESTExecution | WithHeader (string name, string value) |
| Adds an HTTP header to the request client.WithHeader("Authorization", "Bearer YOUR_ACCESS_TOKEN").Execute();. | |
| IAllowRESTExecution | WithTimeout (TimeSpan httpTimeout) |
How long one attempt is given before it is abandoned. Said after the base url, so a client handed a session by ContinueAsRESTClient can still be told, and changed between calls on the same client. | |
| IAllowRESTExecution | WithHeaderFromResult (int resultIndex) |
| Sets the header from a result by index. | |
| IAllowRESTExecution | WithHeaderFromResult (string name) |
| Sets the header from a result by name. | |
| IAllowRESTDragAndDrop | WithDeltaX (int deltaX) |
| Sets the horizontal drop offset for a drag-and-drop operation. | |
| IAllowRESTDragAndDrop | WithDeltaY (int deltaY) |
| Sets the vertical drop offset for a drag-and-drop operation. | |
| IAllowRESTDragAndDrop | WithOffsetX (int offsetX) |
| Sets the horizontal grab offset within the element for a drag-and-drop operation. | |
| IAllowRESTDragAndDrop | WithOffsetY (int offsetY) |
| Sets the vertical grab offset within the element for a drag-and-drop operation. | |
| IAllowRESTScrollElement | WithHPixels (int hPixels) |
| Sets the horizontal pixels parameter. | |
| IAllowRESTScrollElement | WithHPixelsFromResult (int resultIndex) |
| Sets the horizontal pixels from a result by index. | |
| IAllowRESTScrollElement | WithHPixelsFromResult (string name) |
| Sets the horizontal pixels from a result by name. | |
| IAllowRESTScrollElement | WithVPixels (int vPixels) |
| Sets the vertical pixels parameter. | |
| IAllowRESTScrollElement | WithVPixelsFromResult (int resultIndex) |
| Sets the vertical pixels from a result by index. | |
| IAllowRESTScrollElement | WithVPixelsFromResult (string name) |
| Sets the vertical pixels from a result by name. | |
| IAllowRESTExecution | CaptureVisibleTab (ImageFormat imageFormat=ImageFormat.JPEG) |
| Get a screenshot of the current tab visble contents. | |
| IAllowRESTExecution | SetDownloadFilename (string downloadPath) |
| Sets the download filename for the current session client.SetDownloadFilename("/path/to/file").Execute();. | |
| IAllowRESTExecution | WithDownloadFile (string downloadPath) |
| IAllowRESTExecution | Evaluate (string xpath) |
| Evaluates an XPath expression client.Evaluate("//div").Execute();. | |
| IAllowRESTExecution | EvaluateAll (string xpath) |
| Evaluates an XPath expression for multiple elements client.EvaluateAll("//div").Execute<string[]>();. | |
| IAllowRESTExecution | EvaluatePersistent (string xpath) |
| Evaluates an XPath expression client.Evaluate("//div").Execute();. | |
| IAllowRESTExecution | EvaluateAllPersistent (string xpath) |
| Evaluates an XPath expression for multiple elements client.EvaluateAll("//div").Execute<string[]>();. | |
| IAllowRESTExecution | ClearReferrer () |
| Clears the referrer client.ClearReferrer().Execute();. | |
| IAllowRESTExecution | FireChangeEvent (string elementId) |
| Fires a change event on an element by ID client.FireChangeEvent("element123").Execute();. | |
| IAllowRESTExecution | Focus (string elementId) |
| Focuses an element by ID client.Focus("element123").Execute();. | |
| IAllowRESTExecution | GetBoundingClientRect (string elementId) |
| Gets the bounding client rect of an element by ID client.GetBoundingClientRect("element123").Execute<string>();. | |
| IAllowRESTExecution | ElementFromPoint (string elementId, int x, int y) |
| Asks whether a click at this viewport point would reach the element, rather than land on whatever is covering it there. | |
| IAllowRESTExecution | TrustedLeftClick (int x, int y, int holdMs=0) |
| Clicks a viewport point through the browser's own input pipeline, so the page reads the event as trusted. Answers OK when the click was made and NOTOK where the browser has no debugger to attach, which is Firefox. client.TrustedLeftClick(120, 340).Execute<bool>();. | |
| IAllowRESTExecution | TrustedMiddleClick (int x, int y, int holdMs=0) |
| Middle clicks a viewport point through the browser's own input pipeline, so the page reads the event as trusted. Answers OK when the click was made and NOTOK where the browser has no debugger to attach, which is Firefox. client.TrustedMiddleClick(120, 340).Execute<bool>();. | |
| IAllowRESTExecution | GetWindowRectangle () |
| IAllowRESTExecution | GetContentAndCss (string elementId) |
| IAllowRESTExecution | GetCssAttributes (string elementId) |
| IAllowRESTExecution | GetDomAttributes (string elementId) |
| IAllowRESTExecution | GetDomProperties (string elementId) |
| IAllowRESTExecution | GetElementAttributeHash (string elementId) |
| Gets the attribute hash of an element client.GetElementAttributeHash().Execute<string>();. | |
| IAllowRESTExecution | GetOptions (string elementId) |
| Get the options in a Select manue. | |
| IAllowRESTExecution | GetPageSource () |
| IAllowRESTExecution | GetParentNode (string elementId) |
| Gets the parent node of an element by ID client.GetParentNode("element123").Execute<string>();. | |
| IAllowRESTExecution | HideElement (string elementId) |
| Hides an element by ID client.HideElement("element123").Execute();. | |
| IAllowRESTExecution | IsClickable (string elementId) |
| Checks if an element is clickable by ID client.IsClickAble("element123").Execute<bool>();. | |
| IAllowRESTExecution | IsDisplayed (string elementId) |
| Checks if an element is displayed by ID client.IsDisplayed("element123").Execute<bool>();. | |
| IAllowRESTExecution | IsEnabled (string elementId) |
| Checks if an element is enabled by ID client.IsEnabled("element123").Execute<bool>();. | |
| IAllowRESTExecution | IsEndOfPage () |
| Checks if the page is at the end client.IsEndOfPage().Execute<bool>();. | |
| IAllowRESTExecution | IsVisibleInViewport (string elementId) |
| Checks if an element is visible in viewport by ID client.IsVisibleInViewport("element123").Execute<bool>();. | |
| IAllowRESTExecution | LeftClick (string elementId) |
| Performs a left click on an element by ID client.LeftClick("element123").Execute();. | |
| IAllowRESTExecution | LeftDoubleClick (string elementId) |
| Performs a left double click on an element by ID client.LeftDoubleClick("element123").Execute();. | |
| IAllowRESTExecution | MiddleClick (string elementId) |
| Performs a left click on an element by ID client.LeftClick("element123").Execute();. | |
| IAllowRESTExecution | QuerySelector (string css) |
| Queries a single element using a CSS selector client.QuerySelector(".class").Execute();. | |
| IAllowRESTExecution | QuerySelectors (string css) |
| Queries multiple elements using a CSS selector client.QuerySelectors(".class").Execute<string[]>();. | |
| IAllowRESTExecution | QueryPersistentSelector (string css) |
| Queries a single element using a CSS selector client.QuerySelector(".class").Execute();. | |
| IAllowRESTExecution | QueryPersistentSelectors (string css) |
| Queries multiple elements using a CSS selector client.QuerySelectors(".class").Execute<string[]>();. | |
| IAllowRESTExecution | RightClick (string elementId) |
| Performs a right click on an element by ID client.RightClick("element123").Execute();. | |
| IAllowRESTExecution | ScrollIntoView (string elementId) |
| Scrolls an element into view by ID client.ScrollIntoView("element123").Execute();. | |
| IAllowRESTExecution | ScrollElement (int hPixels, int vPixels) |
| Scrolls an element by horizontal and vertical pixels client.ScrollElement(100, 200).Execute();. | |
| IAllowRESTAttribute | GetAttribute (string elementId) |
| Starts getting an attribute of an element by ID client.GetAttribute("element123").WithAttribute("value").Execute<string>();. | |
| IAllowRESTAttribute | SetAttribute (string elementId) |
| Starts setting an attribute of an element by ID client.SetAttribute("element123").WithAttribute("disabled").WithValue("true").Execute();. | |
| IAllowRESTExecution | TopBrowser () |
| Top the browser, bring it into focus. Used before performing any actions on the browser. | |
| IAllowRESTAttribute | WithAttribute (string attribute) |
| Specifies the attribute name for get or set operation client.GetAttribute("element123").WithAttribute("value").Execute<string>();. | |
| IAllowRangeValue | SetRange (string elementId) |
| Starts setting an attribute of an element by ID client.SetAttribute("element123").WithAttribute("disabled").WithValue("true").Execute();. | |
| IAllowRESTExecution | WithRangeValue (int rangeValue) |
| Specifies the value for SetRange operation client.SetRange("element123").WithRangeValue(63).Execute();. | |
| IAllowRESTAttribute | WithValue (string value) |
| Specifies the value for set operation client.SetAttribute("element123").WithAttribute("disabled").WithValue("true").Execute();. | |
| IAllowRESTExecution | WindowInnerHeight () |
| Gets the window inner height client.WindowInnerHeight().Execute<int>();. | |
| IAllowRESTExecution | WindowInnerWidth () |
| Gets the window inner width client.WindowInnerWidth().Execute<int>();. | |
| IAllowRESTExecution | WindowOuterHeight () |
| Gets the window outer height client.WindowOuterHeight().Execute<int>();. | |
| IAllowRESTExecution | WindowOuterWidth () |
| Gets the window outer width client.WindowOuterWidth().Execute<int>();. | |
| IAllowRESTParametersOrExecution | Fetch (string url) |
| Issue an API request from inside the page, so it carries the session the browser has already earned: its cookies, TLS fingerprint, header order and any anti-bot clearance. A relative url resolves against wherever the browser currently is. client.Fetch("/api/search?page=1").Execute();. | |
| IAllowRESTParametersOrExecution | WithVerb (string method) |
| Sets the verb of the request being fetched. Not .WithHttpMethod, which is the verb of the REST call itself. GET when nothing was said. client.Fetch(url).WithVerb("POST").Execute();. | |
| IAllowRESTParametersOrExecution | WithBody (string body) |
| Sets the body of the request being fetched. client.Fetch(url).WithVerb("POST").WithBody(json).Execute();. | |
| IAllowRESTParametersOrExecution | WithContentType (string contentType) |
| Sets the content type of the body of the request being fetched. client.Fetch(url).WithContentType("application/json").Execute();. | |
| IAllowRESTParametersOrExecution | WithHeaders (string[] headers) |
| Sets extra headers for the request being fetched, flattened to name, value, name, value. client.Fetch(url).WithHeaders(new[] { "Accept", "application/json" }).Execute();. | |
| IAllowRESTParametersOrExecution | WithBytes (bool bytes) |
| True to bring the fetched response body back base64 encoded, which is what a file needs. Text is the default, and reading a file as text would put a replacement character wherever a byte is not valid utf-8. client.Fetch(url).WithBytes(true).Execute();. | |
| IAllowRESTExecution | WindowPageOffsetX () |
| Gets the window page offset X client.WindowPageOffsetX().Execute<int>();. | |
| IAllowRESTExecution | WindowPageOffsetY () |
| Gets the window page offset Y client.WindowPageOffsetY().Execute<int>();. | |
| IAllowRESTExecution | WindowScreenLeft () |
| Gets the window screen left position client.WindowScreenLeft().Execute<int>();. | |
| IAllowRESTExecution | WindowScreenTop () |
| Gets the window screen top position client.WindowScreenTop().Execute<int>();. | |
| IAllowRESTExecution | Hover (string elementId) |
| Hovers over an element by ID client.Hover("element123").Execute();. | |
| IAllowRESTExecution | Back () |
| Navigates browser history back client.Back().Execute();. | |
| IAllowRESTExecution | CheckNetworkIdle (int maxConnections=0) |
| Checks if network is idle with max connections client.CheckNetworkIdle(5).Execute<bool>();. | |
| IAllowRESTExecution | CloseTab (int tabId) |
| Closes a tab by tab ID client.CloseTab(1).Execute();. | |
| IAllowRESTExecution | CloseTab (GPALUrl url=null) |
| Closes a tab by URL client.CloseTab("https://example.com").Execute();. | |
| IAllowRESTParameters | ExecuteJavaScript (string script) |
| Executes JavaScript code client.ExecuteJavaScript("return document.title").Execute<string>();. | |
| IAllowRESTParameters | InjectScript (string script) |
| Registers a script to run on every new document load. Persists until ClearInjectedScripts is called. | |
| IAllowRESTParameters | ClearInjectedScripts () |
| Removes all scripts previously registered via InjectScript(string). | |
| IAllowRESTExecution | Forward () |
| Navigates browser history forward client.Forward().Execute();. | |
| IAllowRESTExecution | FullScreen () |
| Sets browser to full screen client.FullScreen().Execute();. | |
| IAllowRESTExecution | GetBrowserSettings () |
| Gets browser settings client.GetBrowserSettings().Execute();. | |
| IAllowRESTExecution | GetCurrentUrl () |
| Gets the current URL client.GetCurrentUrl().Execute<string>();. | |
| IAllowRESTExecution | GetDocumentStamp () |
| Gets the current URL and the document identity in one call. A form posting to itself and a route rewritten in place both build a new document at the same address, which the url alone does not distinguish. client.GetDocumentStamp().Execute<string>();. | |
| IAllowRESTExecution | GetHydrationScripts () |
| Gets the page title, the NEXT_DATA payload and any React Flight chunks, read from the document rather than its markup. client.GetHydrationScripts().Execute<string>();. | |
| IAllowRESTExecution | GetGpalSettings () |
| Gets GPAL settings client.GetGpalSettings().Execute();. | |
| IAllowRESTExecution | GetReadyStatus () |
| Gets the ready status client.GetReadyStatus().Execute<string>();. | |
| IAllowRESTExecution | GetSettings () |
| Gets settings client.GetSettings().Execute();. | |
| IAllowRESTExecution | GetShadowRoot (string css) |
| Gets the shadow root for a CSS selector client.GetShadowRoot(".class").Execute();. | |
| IAllowRESTExecution | GetLanguages () |
| Gets the browser's preferred languages, most preferred first client.GetLanguages().Execute<string>();. | |
| IAllowRESTCaptureOptions | CaptureCalls (bool capture=true) |
| Starts or stops recording what the page asks for. Narrow it with WithCallFilter and start from nothing with WithClearCalls. client.CaptureCalls(true).WithCallFilter("/api/search").Execute();. | |
| IAllowRESTCaptureOptions | WithCallFilter (string urlFragment) |
| Records only the calls whose url holds this, so a page that talks to a dozen places narrows to the one worth having. | |
| IAllowRESTCaptureOptions | WithClearCalls (bool clear=true) |
| Forgets what was already recorded before starting, so a second capture is not read as the first. | |
| IAllowRESTExecution | GetCapturedCalls () |
| Everything recorded so far, oldest first, as the json the extension keeps. string json = client.GetCapturedCalls().Execute();. | |
| IAllowRESTExecution | GetUserAgent () |
| Gets the user agent client.GetUserAgent().Execute<string>();. | |
| IAllowRESTExecution | GetWorkflow () |
| Gets the workflow client.GetWorkflow().Execute();. | |
| IAllowRESTExecution | GoTo (GPALUrl url) |
| Navigates to a URL client.Goto("https://example.com").Execute();. | |
| IAllowRESTExecution | GoToTab (int tabId) |
| Navigates to a tab by tab ID client.GotoTab(1).Execute();. | |
| IAllowRESTExecution | GoToTab (GPALUrl url) |
| Navigates to a tab by URL client.GotoTab("https://example.com").Execute();. | |
| IAllowRESTInputText | FillInAppend (string elementId) |
| Appends text to an element client.FillInAppend("input123").WithText("Hello").Execute();. | |
| IAllowRESTInputText | FillInInsert (string elementId) |
| Appends text to an element client.FillInAppend("input123").WithText("Hello").Execute();. | |
| IAllowRESTInputText | FillInOverwrite (string elementId) |
| Appends text to an element client.FillInAppend("input123").WithText("Hello").Execute();. | |
| IAllowRESTWithDownloadFilename | LeftClickAndDownload (string elementId) |
| Performs a left click and download on an element client.LeftClickAndDownload("element123").SetDownloadFileName(fileName).Execute();. | |
| IAllowRESTWithUploadFilename | LeftClickAndUpload (string elementId) |
| Purely headless mode, attaches the file to the input[type=file] client.LeftClickAndUpload("element123").WithUploadFile(filePath).Execute();. | |
| IAllowRESTExecution | Maximize () |
| Maximizes the browser window client.Maximize().Execute();. | |
| IAllowRESTExecution | Minimize () |
| Minimizes the browser window client.Minimize().Execute();. | |
| IAllowRESTExecution | MoveTo (string elementId) |
| Moves to an element client.MoveTo("element123").Execute();. | |
| IAllowRESTExecution | NewTab (GPALUrl url) |
| Opens a new tab with optional URL client.NewTab("https://example.com").Execute();. | |
| IAllowRESTExecution | NextTab () |
| Switches to the next tab client.NextTab().Execute();. | |
| IAllowRESTExecution | TabCount () |
| How many tabs the browser actually has open, which is not the same as how many GPAL opened. A tab can close itself, which is what a browser does with a tab whose first navigation turns into a download. int tabs = client.TabCount().Execute<int>();. | |
| IAllowRESTExecution | NextWindow () |
| Switches to the next window client.NextTab().Execute();. | |
| IAllowRESTExecution | Normal () |
| Restores the browser window to normal client.Normal().Execute();. | |
| IAllowRESTExecution | OverrideReferrer (string referrer) |
| Overrides the referrer URL client.OverrideReferrr("https://google.com").Execute();. | |
| IAllowRESTExecution | SetUserAgent (string userAgent) |
| Overrides the browser's user agent string client.SetUserAgent("Mozilla/5.0 ...").Execute();. | |
| IAllowRESTExecution | PageDown (int pagesToScroll=1) |
| Scrolls the page down by pages client.PageDown(1).Execute();. | |
| IAllowRESTExecution | PageEnd () |
| Scrolls to the page end client.PageEnd().Execute();. | |
| IAllowRESTExecution | PageTop () |
| Scrolls to the page top client.PageTop().Execute();. | |
| IAllowRESTExecution | PageUp (int pagesToScroll=1) |
| Scrolls the page up by pages client.PageUp(1).Execute();. | |
| IAllowRESTExecution | PressModifierKey (ModifierKeys modifierKeys) |
| Press the modifier keys specified. Keep pressed until a release is sent. | |
| IAllowRESTExecution | PreviousTab () |
| Switches to the previous tab client.PreviousTab().Execute();. | |
| IAllowRESTExecution | PreviousWindow () |
| Switches to the next window client.NextTab().Execute();. | |
| IAllowRESTExecution | Refresh () |
| Refreshes the current page client.Refresh().Execute();. | |
| IAllowRESTExecution | ReleaseModifierKey (ModifierKeys modifierKeys) |
| Press the modifier keys specified. Keep pressed until a release is sent. | |
| IAllowRESTExecution | Restore () |
| Restores the browser window client.Restore().Execute();. | |
| IAllowRESTDragAndDrop | DragAndDrop (string elementId) |
| Drags an element from its current position by the given offset and drops it client.DragAndDrop("element123").WithDeltaX(100).WithDeltaY(50).Execute();. | |
| IAllowRESTScrollElement | ScrollElement (string elementId) |
| Starts scrolling an element by ID client.ScrollElement("element123").WithHPixels(100).WithVPixels(200).Execute();. | |
| IAllowRESTExecution | ScrollWindow (int hPixels, int vPixels) |
| IAllowRESTExecution | ScrollWindowByHorizontal (int hPixels) |
| Scrolls the window horizontally by pixels client.ScrollWindowByHorizontal(100).Execute();. | |
| IAllowRESTExecution | ScrollWindowByVertical (int vPixels) |
| Scrolls the window vertically by pixels client.ScrollWindowByVertical(100).Execute();. | |
| IAllowSelectOptions | SelectClick (string elementId) |
| Click a Select menu option. | |
| IAllowRESTExecution | WithSelectValue (string selectValue) |
| Set the value to choose from the Select menu. | |
| IAllowRESTExecution | WithSelectIndex (int selectIndex) |
| IAllowRESTExecution | SendKey (byte vkcode) |
| Sends a key client.SendKey("Enter").Execute();. | |
| IAllowRESTExecution | SendString (string text, int delayMs=0) |
| Sends a string client.SendString("Hello").Execute();. | |
| IAllowRESTParametersOrExecution | SetValueFrom (string destSelector) |
| Sets the value of the destination element identified by destSelector from the source element identified by the preceding WithCss(string) or WithElementId(string) call. client.WithElementId("srcSelector").SetValueFrom("destSelector").Execute();. | |
| IAllowRESTExecution | SetGoogleReferrer () |
| Overrides referrer stealthily - sets to google.com client.SetGoogleReferrer().Execute();. | |
| IAllowRESTExecution | SwitchToDefaultContent () |
| Switches to default content client.SwitchToDefaultContent().Execute();. | |
| IAllowRESTParametersOrExecution | WithWindowId (int windowId) |
| Sets the window ID parameter client.CloseWindow(123).Execute<WindowTuple>();. | |
| IAllowRESTParametersOrExecution | WithWindowIdFromResult (int resultIndex) |
| Sets the window ID from a result by index client.GoToWindow().WithWindowIdFromResult(0).Execute<WindowTuple>();. | |
| IAllowRESTParametersOrExecution | WithWindowIdFromResult (string name) |
| Sets the window ID from a result by name client.GoToWindow().WithWindowIdFromResult("windowResult").Execute<WindowTuple>();. | |
| IAllowRESTExecution | OpenWindow (GPALUrl url) |
| Opens a new window with the specified URL client.OpenWindow("https://example.com").Execute<WindowTuple>();. | |
| IAllowRESTExecution | GoToWindow (GPALUrl url) |
| Switches to a window by URL client.GoToWindow("https://example.com").Execute<WindowTuple>();. | |
| IAllowRESTExecution | GoToWindow (int windowId) |
| Switches to a window by window ID client.GoToWindow(123).Execute<WindowTuple>();. | |
| IAllowRESTExecution | CloseBrowser () |
| Closes every window the browser has, which is how it is asked to quit client.CloseBrowser().Execute();. | |
| IAllowRESTExecution | CloseWindow (GPALUrl url) |
| Closes a window by URL, optionally switching to the main window client.CloseWindow("https://example.com").Execute<WindowTuple>();. | |
| IAllowRESTExecution | CloseWindow (int windowId) |
| Closes a window by window ID, optionally switching to the main window client.CloseWindow(123).Execute<WindowTuple>();. | |
| IAllowRESTStorageOptions | DeleteStorage (WebsiteStorageType storageType) |
| Delete the specified storage type. | |
| IAllowRESTStorageOptions | GetStorage (WebsiteStorageType storageType) |
| Get the specified storage type. | |
| IAllowRESTStorageOptions | SetStorage (WebsiteStorageType storageType) |
| Set data for the specified storage type. | |
| IAllowRESTExecution | GetCurrentWindow () |
| Gets the current window's ID and URL client.GetCurrentWindow().Execute<WindowTuple>();. | |
| IAllowRESTExecution | SwitchToElement (string elementId) |
| Switches to an element to search for selectors contained client.SwitchToElement("div123").Execute();. | |
| IAllowRESTExecution | SwitchToFrame (string elementId) |
| Switches to a frame client.SwitchToFrame("frame123").Execute();. | |
| IAllowRESTExecution | SwitchToShadowRoot (string elementId) |
| Switches to a shadow root client.SwitchToShadowRoot("shadow123").Execute();. | |
| Public Member Functions inherited from GenerallyPositive.IAllowRESTParameters | |
| IAllowRESTParametersOrExecution | WithEncoding (Enums.ContentEncoding encoding) |
Properties | |
| int | StatusCode [get] |
| The HTTP status code the last call came back with. | |
| int | RetryAfterSeconds [get] |
| The seconds the last call was asked to wait before asking again, zero when it was not asked. | |
| string | Name [get, set] |
| Gets or sets the client name. | |
Fluent REST client for making API calls with a chained interface. Supports defining workflows, executing them in loops, and accessing results. Results are accessed via a non-generic indexer, requiring casting to the desired type.
Definition at line 55 of file RESTClient.cs.
| IRESTClient GenerallyPositive.RESTClient.AndThen | ( | bool | publishEvent = true | ) |
Executes and chains the request.
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1518 of file RESTClient.cs.
| IRESTClient GenerallyPositive.RESTClient.AndThen< T > | ( | bool | publishEvent = true | ) |
Executes and chains the request with type.
| T | The result type |
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1531 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.Back | ( | ) |
Navigates browser history back client.Back().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2941 of file RESTClient.cs.
| IAllowRESTCaptureOptions GenerallyPositive.RESTClient.CaptureCalls | ( | bool | capture = true | ) |
Starts or stops recording what the page asks for. Narrow it with WithCallFilter and start from nothing with WithClearCalls. client.CaptureCalls(true).WithCallFilter("/api/search").Execute();.
| capture | True to record, false to stop |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3160 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.CaptureVisibleTab | ( | ImageFormat | imageFormat = ImageFormat::JPEG | ) |
Get a screenshot of the current tab visble contents.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2165 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.CheckNetworkIdle | ( | int | maxConnections = 0 | ) |
Checks if network is idle with max connections client.CheckNetworkIdle(5).Execute<bool>();.
| maxConnections | Maximum connections allowed |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2953 of file RESTClient.cs.
| IAllowRESTParameters GenerallyPositive.RESTClient.ClearInjectedScripts | ( | ) |
Removes all scripts previously registered via InjectScript(string).
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3021 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.ClearReferrer | ( | ) |
Clears the referrer client.ClearReferrer().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2252 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.ClearResults | ( | ) |
Empties what WithResultName has stored, so GetExecutionResults answers about what has happened since rather than everything since the client was made.
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1727 of file RESTClient.cs.
| IAllowRESTWorkflow GenerallyPositive.RESTClient.ClearWorkflows | ( | ) |
Gets the execution results.
Empties the workflow steps declared with WithWorkflow, so the next While or Until loop runs a new set rather than that one plus everything added before it. Steps otherwise stay on the client for as long as it lives, which is what lets the same set be run more than once.
Implements GenerallyPositive.IAllowRESTWorkflow.
Definition at line 1712 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.CloseBrowser | ( | ) |
Closes every window the browser has, which is how it is asked to quit client.CloseBrowser().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3854 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.CloseTab | ( | GPALUrl | url = null | ) |
Closes a tab by URL client.CloseTab("https://example.com").Execute();.
| url | The URL (optional) |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2977 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.CloseTab | ( | int | tabId | ) |
Closes a tab by tab ID client.CloseTab(1).Execute();.
| tabId | The tab ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2965 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.CloseWindow | ( | GPALUrl | url | ) |
Closes a window by URL, optionally switching to the main window client.CloseWindow("https://example.com").Execute<WindowTuple>();.
| url | The window URL |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3866 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.CloseWindow | ( | int | windowId | ) |
Closes a window by window ID, optionally switching to the main window client.CloseWindow(123).Execute<WindowTuple>();.
| windowId | The window ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3882 of file RESTClient.cs.
| IAllowRESTStorageOptions GenerallyPositive.RESTClient.DeleteStorage | ( | WebsiteStorageType | storageType | ) |
Delete the specified storage type.
| storageType |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3893 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.DownloadTo | ( | GPALFile | downloadPath | ) |
Where a file the browser downloads should end up.
Not SaveTo, which is GPAL writing a file it already has. This is a request the browser carries out, and what it can honor differs by engine: the extension names the download but cannot place it, so the file arrives in the browser's own download directory and the download watcher moves it here. client.WithEndpoint(ApiEndpoint.LeftClickAndDownload).DownloadTo(file).Execute();.
| downloadPath | Where the downloaded file is to end up |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1255 of file RESTClient.cs.
| IAllowRESTDragAndDrop GenerallyPositive.RESTClient.DragAndDrop | ( | string | elementId | ) |
Drags an element from its current position by the given offset and drops it client.DragAndDrop("element123").WithDeltaX(100).WithDeltaY(50).Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3594 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.ElementFromPoint | ( | string | elementId, |
| int | x, | ||
| int | y ) |
Asks whether a click at this viewport point would reach the element, rather than land on whatever is covering it there.
| elementId | The element that should receive the click |
| x | Viewport x |
| y | Viewport y |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2302 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.Evaluate | ( | string | xpath | ) |
Evaluates an XPath expression client.Evaluate("//div").Execute();.
| xpath | The XPath expression |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2205 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.EvaluateAll | ( | string | xpath | ) |
Evaluates an XPath expression for multiple elements client.EvaluateAll("//div").Execute<string[]>();.
| xpath | The XPath expression |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2217 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.EvaluateAllPersistent | ( | string | xpath | ) |
Evaluates an XPath expression for multiple elements client.EvaluateAll("//div").Execute<string[]>();.
| xpath | The XPath expression |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2241 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.EvaluatePersistent | ( | string | xpath | ) |
Evaluates an XPath expression client.Evaluate("//div").Execute();.
| xpath | The XPath expression |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2229 of file RESTClient.cs.
| string GenerallyPositive.RESTClient.Execute | ( | bool | publishEvent = true | ) |
Executes the request synchronously.
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1345 of file RESTClient.cs.
| T GenerallyPositive.RESTClient.Execute< T > | ( | bool | publishEvent = true | ) |
Executes the request synchronously with type.
| T | The result type |
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1428 of file RESTClient.cs.
| async Task< string > GenerallyPositive.RESTClient.ExecuteAsync | ( | bool | publishEvent = true | ) |
Executes the request asynchronously and returns the raw response await client.ExecuteAsync();.
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1544 of file RESTClient.cs.
| async Task< T > GenerallyPositive.RESTClient.ExecuteAsync< T > | ( | bool | publishEvent = true | ) |
Executes the request asynchronously with type.
| T | The result type |
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1622 of file RESTClient.cs.
| IAllowRESTParameters GenerallyPositive.RESTClient.ExecuteJavaScript | ( | string | script | ) |
Executes JavaScript code client.ExecuteJavaScript("return document.title").Execute<string>();.
| script | The JavaScript code |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2992 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.Fetch | ( | string | url | ) |
Issue an API request from inside the page, so it carries the session the browser has already earned: its cookies, TLS fingerprint, header order and any anti-bot clearance. A relative url resolves against wherever the browser currently is. client.Fetch("/api/search?page=1").Execute();.
| url | Url to request, relative or absolute |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2777 of file RESTClient.cs.
| IAllowRESTInputText GenerallyPositive.RESTClient.FillInAppend | ( | string | elementId | ) |
Appends text to an element client.FillInAppend("input123").WithText("Hello").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3282 of file RESTClient.cs.
| IAllowRESTInputText GenerallyPositive.RESTClient.FillInInsert | ( | string | elementId | ) |
Appends text to an element client.FillInAppend("input123").WithText("Hello").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3294 of file RESTClient.cs.
| IAllowRESTInputText GenerallyPositive.RESTClient.FillInOverwrite | ( | string | elementId | ) |
Appends text to an element client.FillInAppend("input123").WithText("Hello").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3306 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.FireChangeEvent | ( | string | elementId | ) |
Fires a change event on an element by ID client.FireChangeEvent("element123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2264 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.Focus | ( | string | elementId | ) |
Focuses an element by ID client.Focus("element123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2276 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.Forward | ( | ) |
Navigates browser history forward client.Forward().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3033 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.FullScreen | ( | ) |
Sets browser to full screen client.FullScreen().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3044 of file RESTClient.cs.
| IAllowRESTAttribute GenerallyPositive.RESTClient.GetAttribute | ( | string | elementId | ) |
Starts getting an attribute of an element by ID client.GetAttribute("element123").WithAttribute("value").Execute<string>();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2640 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetBoundingClientRect | ( | string | elementId | ) |
Gets the bounding client rect of an element by ID client.GetBoundingClientRect("element123").Execute<string>();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2288 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetBrowserSettings | ( | ) |
Gets browser settings client.GetBrowserSettings().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3055 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetCapturedCalls | ( | ) |
Everything recorded so far, oldest first, as the json the extension keeps. string json = client.GetCapturedCalls().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3208 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetContentAndCss | ( | string | elementId | ) |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2369 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetCssAttributes | ( | string | elementId | ) |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2378 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetCurrentUrl | ( | ) |
Gets the current URL client.GetCurrentUrl().Execute<string>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3066 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetCurrentWindow | ( | ) |
Gets the current window's ID and URL client.GetCurrentWindow().Execute<WindowTuple>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3928 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetDocumentStamp | ( | ) |
Gets the current URL and the document identity in one call.
A form posting to itself and a route rewritten in place both build a new document at the same address, which the url alone does not distinguish. client.GetDocumentStamp().Execute<string>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3079 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetDomAttributes | ( | string | elementId | ) |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2387 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetDomProperties | ( | string | elementId | ) |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2396 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetElementAttributeHash | ( | string | elementId | ) |
Gets the attribute hash of an element client.GetElementAttributeHash().Execute<string>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2410 of file RESTClient.cs.
| ResultCollection GenerallyPositive.RESTClient.GetExecutionResults | ( | ) |
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1733 of file RESTClient.cs.
| IReadOnlyList< object > GenerallyPositive.RESTClient.GetExecutionResults | ( | string | name | ) |
Every result stored under name , in the order it was stored, so a loop that ran five times answers with five. Ask without a name for the whole collection, or index it by name for the last answer alone.
| name | The name given to WithResultName |
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1746 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetGpalSettings | ( | ) |
Gets GPAL settings client.GetGpalSettings().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3102 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetHydrationScripts | ( | ) |
Gets the page title, the NEXT_DATA payload and any React Flight chunks, read from the document rather than its markup. client.GetHydrationScripts().Execute<string>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3091 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetLanguages | ( | ) |
Gets the browser's preferred languages, most preferred first client.GetLanguages().Execute<string>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3147 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetOptions | ( | string | elementId | ) |
Get the options in a Select manue.
| elementId |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2421 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetPageSource | ( | ) |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2426 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetParentNode | ( | string | elementId | ) |
Gets the parent node of an element by ID client.GetParentNode("element123").Execute<string>();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2437 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetReadyStatus | ( | ) |
Gets the ready status client.GetReadyStatus().Execute<string>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3113 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetSettings | ( | ) |
Gets settings client.GetSettings().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3124 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetShadowRoot | ( | string | css | ) |
Gets the shadow root for a CSS selector client.GetShadowRoot(".class").Execute();.
| css | The CSS selector |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3136 of file RESTClient.cs.
| IAllowRESTStorageOptions GenerallyPositive.RESTClient.GetStorage | ( | WebsiteStorageType | storageType | ) |
Get the specified storage type.
| storageType |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3905 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetUserAgent | ( | ) |
Gets the user agent client.GetUserAgent().Execute<string>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3219 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetWindowRectangle | ( | ) |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2364 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GetWorkflow | ( | ) |
Gets the workflow client.GetWorkflow().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3230 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GoTo | ( | GPALUrl | url | ) |
Navigates to a URL client.Goto("https://example.com").Execute();.
| url | The URL |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3242 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GoToTab | ( | GPALUrl | url | ) |
Navigates to a tab by URL client.GotoTab("https://example.com").Execute();.
| url | The URL |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3270 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GoToTab | ( | int | tabId | ) |
Navigates to a tab by tab ID client.GotoTab(1).Execute();.
| tabId | The tab ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3258 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GoToWindow | ( | GPALUrl | url | ) |
Switches to a window by URL client.GoToWindow("https://example.com").Execute<WindowTuple>();.
| url | The window URL |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3831 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.GoToWindow | ( | int | windowId | ) |
Switches to a window by window ID client.GoToWindow(123).Execute<WindowTuple>();.
| windowId | The window ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3843 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.HideElement | ( | string | elementId | ) |
Hides an element by ID client.HideElement("element123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2449 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.Hover | ( | string | elementId | ) |
Hovers over an element by ID client.Hover("element123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2914 of file RESTClient.cs.
| IAllowRESTParameters GenerallyPositive.RESTClient.InjectScript | ( | string | script | ) |
Registers a script to run on every new document load. Persists until ClearInjectedScripts is called.
| script | The JavaScript code to inject |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3007 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.IsClickable | ( | string | elementId | ) |
Checks if an element is clickable by ID client.IsClickAble("element123").Execute<bool>();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2461 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.IsDisplayed | ( | string | elementId | ) |
Checks if an element is displayed by ID client.IsDisplayed("element123").Execute<bool>();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2473 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.IsEnabled | ( | string | elementId | ) |
Checks if an element is enabled by ID client.IsEnabled("element123").Execute<bool>();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2485 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.IsEndOfPage | ( | ) |
Checks if the page is at the end client.IsEndOfPage().Execute<bool>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2496 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.IsVisibleInViewport | ( | string | elementId | ) |
Checks if an element is visible in viewport by ID client.IsVisibleInViewport("element123").Execute<bool>();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2508 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.LeftClick | ( | string | elementId | ) |
Performs a left click on an element by ID client.LeftClick("element123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2520 of file RESTClient.cs.
| IAllowRESTWithDownloadFilename GenerallyPositive.RESTClient.LeftClickAndDownload | ( | string | elementId | ) |
Performs a left click and download on an element client.LeftClickAndDownload("element123").SetDownloadFileName(fileName).Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3318 of file RESTClient.cs.
| IAllowRESTWithUploadFilename GenerallyPositive.RESTClient.LeftClickAndUpload | ( | string | elementId | ) |
Purely headless mode, attaches the file to the input[type=file] client.LeftClickAndUpload("element123").WithUploadFile(filePath).Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3330 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.LeftDoubleClick | ( | string | elementId | ) |
Performs a left double click on an element by ID client.LeftDoubleClick("element123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2532 of file RESTClient.cs.
| IAllowRESTEndpointDetails GenerallyPositive.RESTClient.ListOpenAPIEndPoints | ( | ) |
Implements GenerallyPositive.IAllowRESTEndpointDetails.
Definition at line 465 of file RESTClient.cs.
| IAllowRESTEndpointDetails GenerallyPositive.RESTClient.LoadOpenAPIMap | ( | GPALFile | openApiMapFile | ) |
Implements GenerallyPositive.IAllowRESTEndpoint.
Definition at line 392 of file RESTClient.cs.
| IAllowRESTEndpointDetails GenerallyPositive.RESTClient.LoadOpenAPIMap | ( | string | yamlOrUrl | ) |
Implements GenerallyPositive.IAllowRESTEndpoint.
Definition at line 339 of file RESTClient.cs.
| void GenerallyPositive.RESTClient.LoadOpenApiRulesInternal | ( | string | yamlContent | ) |
Definition at line 408 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.Maximize | ( | ) |
Maximizes the browser window client.Maximize().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3341 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.MiddleClick | ( | string | elementId | ) |
Performs a left click on an element by ID client.LeftClick("element123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2543 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.Minimize | ( | ) |
Minimizes the browser window client.Minimize().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3352 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.MoveTo | ( | string | elementId | ) |
Moves to an element client.MoveTo("element123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3364 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.NewTab | ( | GPALUrl | url | ) |
Opens a new tab with optional URL client.NewTab("https://example.com").Execute();.
| url | The URL (optional) |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3376 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.NextTab | ( | ) |
Switches to the next tab client.NextTab().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3392 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.NextWindow | ( | ) |
Switches to the next window client.NextTab().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3415 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.Normal | ( | ) |
Restores the browser window to normal client.Normal().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3426 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.OpenWindow | ( | GPALUrl | url | ) |
Opens a new window with the specified URL client.OpenWindow("https://example.com").Execute<WindowTuple>();.
| url | The URL to open (optional, defaults to "https://google.com") |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3816 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.OverrideReferrer | ( | string | referrer | ) |
Overrides the referrer URL client.OverrideReferrr("https://google.com").Execute();.
| referrer | The referrer URL |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3438 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.PageDown | ( | int | pagesToScroll = 1 | ) |
Scrolls the page down by pages client.PageDown(1).Execute();.
| pagesToScroll | Number of pages to scroll |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3466 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.PageEnd | ( | ) |
Scrolls to the page end client.PageEnd().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3481 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.PageTop | ( | ) |
Scrolls to the page top client.PageTop().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3492 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.PageUp | ( | int | pagesToScroll = 1 | ) |
Scrolls the page up by pages client.PageUp(1).Execute();.
| pagesToScroll | Number of pages to scroll |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3504 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.PressModifierKey | ( | ModifierKeys | modifierKeys | ) |
Press the modifier keys specified. Keep pressed until a release is sent.
| modifierKeys |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3519 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.PreviousTab | ( | ) |
Switches to the previous tab client.PreviousTab().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3533 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.PreviousWindow | ( | ) |
Switches to the next window client.NextTab().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3544 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.QueryPersistentSelector | ( | string | css | ) |
Queries a single element using a CSS selector client.QuerySelector(".class").Execute();.
| css | The CSS selector |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2579 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.QueryPersistentSelectors | ( | string | css | ) |
Queries multiple elements using a CSS selector client.QuerySelectors(".class").Execute<string[]>();.
| css | The CSS selector |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2591 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.QuerySelector | ( | string | css | ) |
Queries a single element using a CSS selector client.QuerySelector(".class").Execute();.
| css | The CSS selector |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2555 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.QuerySelectors | ( | string | css | ) |
Queries multiple elements using a CSS selector client.QuerySelectors(".class").Execute<string[]>();.
| css | The CSS selector |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2567 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.Refresh | ( | ) |
Refreshes the current page client.Refresh().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3555 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.ReleaseModifierKey | ( | ModifierKeys | modifierKeys | ) |
Press the modifier keys specified. Keep pressed until a release is sent.
| modifierKeys |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3567 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.Restore | ( | ) |
Restores the browser window client.Restore().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3582 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.RightClick | ( | string | elementId | ) |
Performs a right click on an element by ID client.RightClick("element123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2603 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.SaveResultsTo | ( | GPALFile | file | ) |
Saves the response to a file if the endpoint returns a downloadable content client.WithEndpoint(ApiEndpoint.LeftClickAndDownload).SaveResultsTo(file).Execute();.
| file | The GPAL file defining the save location |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1276 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.ScrollElement | ( | int | hPixels, |
| int | vPixels ) |
Scrolls an element by horizontal and vertical pixels client.ScrollElement(100, 200).Execute();.
| hPixels | The horizontal pixels |
| vPixels | The vertical pixels |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2628 of file RESTClient.cs.
| IAllowRESTScrollElement GenerallyPositive.RESTClient.ScrollElement | ( | string | elementId | ) |
Starts scrolling an element by ID client.ScrollElement("element123").WithHPixels(100).WithVPixels(200).Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3606 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.ScrollIntoView | ( | string | elementId | ) |
Scrolls an element into view by ID client.ScrollIntoView("element123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2615 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.ScrollWindow | ( | int | hPixels, |
| int | vPixels ) |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3612 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.ScrollWindowByHorizontal | ( | int | hPixels | ) |
Scrolls the window horizontally by pixels client.ScrollWindowByHorizontal(100).Execute();.
| pixels | The horizontal pixels |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3623 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.ScrollWindowByVertical | ( | int | vPixels | ) |
Scrolls the window vertically by pixels client.ScrollWindowByVertical(100).Execute();.
| pixels | The vertical pixels |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3637 of file RESTClient.cs.
| IAllowSelectOptions GenerallyPositive.RESTClient.SelectClick | ( | string | elementId | ) |
Click a Select menu option.
| elementId |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3650 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.SendKey | ( | byte | vkcode | ) |
Sends a key client.SendKey("Enter").Execute();.
| key | The key to send |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3684 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.SendString | ( | string | text, |
| int | delayMs = 0 ) |
Sends a string client.SendString("Hello").Execute();.
| text | The text to send |
| delayMs | Inter-character pacing delay in milliseconds. 0 sends the whole string atomically; greater than 0 dispatches character-by-character with this delay between characters. |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3709 of file RESTClient.cs.
| IAllowRESTAttribute GenerallyPositive.RESTClient.SetAttribute | ( | string | elementId | ) |
Starts setting an attribute of an element by ID client.SetAttribute("element123").WithAttribute("disabled").WithValue("true").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2652 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.SetDownloadFilename | ( | string | downloadPath | ) |
Sets the download filename for the current session client.SetDownloadFilename("/path/to/file").Execute();.
| downloadPath | The download path |
Names where the next download the browser starts should be saved, without clicking anything.
client.SetDownloadFilename("c: empile.pdf").Execute();</example> <param name="downloadPath">Where the file is to be saved
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2183 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.SetGoogleReferrer | ( | ) |
Overrides referrer stealthily - sets to google.com client.SetGoogleReferrer().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3742 of file RESTClient.cs.
| IAllowRangeValue GenerallyPositive.RESTClient.SetRange | ( | string | elementId | ) |
Starts setting an attribute of an element by ID client.SetAttribute("element123").WithAttribute("disabled").WithValue("true").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2689 of file RESTClient.cs.
| IAllowRESTStorageOptions GenerallyPositive.RESTClient.SetStorage | ( | WebsiteStorageType | storageType | ) |
Set data for the specified storage type.
| storageType |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3917 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.SetUserAgent | ( | string | userAgent | ) |
Overrides the browser's user agent string client.SetUserAgent("Mozilla/5.0 ...").Execute();.
| userAgent | The user agent string to use |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3450 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.SetValueFrom | ( | string | destSelector | ) |
Sets the value of the destination element identified by destSelector from the source element identified by the preceding WithCss(string) or WithElementId(string) call. client.WithElementId("srcSelector").SetValueFrom("destSelector").Execute();.
| destSelector | CSS selector identifying the destination element whose value is set |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 3727 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.SwitchToDefaultContent | ( | ) |
Switches to default content client.SwitchToDefaultContent().Execute();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3753 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.SwitchToElement | ( | string | elementId | ) |
Switches to an element to search for selectors contained client.SwitchToElement("div123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3940 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.SwitchToFrame | ( | string | elementId | ) |
Switches to a frame client.SwitchToFrame("frame123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3956 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.SwitchToShadowRoot | ( | string | elementId | ) |
Switches to a shadow root client.SwitchToShadowRoot("shadow123").Execute();.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3972 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.TabCount | ( | ) |
How many tabs the browser actually has open, which is not the same as how many GPAL opened. A tab can close itself, which is what a browser does with a tab whose first navigation turns into a download. int tabs = client.TabCount().Execute<int>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 3404 of file RESTClient.cs.
| IRESTClient GenerallyPositive.RESTClient.ToGPALObject | ( | ) |
Converts the client to a GPAL object.
Implements GenerallyPositive.IAllowToGPALObject< TResult >.
Definition at line 1696 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.TopBrowser | ( | ) |
Top the browser, bring it into focus. Used before performing any actions on the browser.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2662 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.TrustedLeftClick | ( | int | x, |
| int | y, | ||
| int | holdMs = 0 ) |
Clicks a viewport point through the browser's own input pipeline, so the page reads the event as trusted. Answers OK when the click was made and NOTOK where the browser has no debugger to attach, which is Firefox. client.TrustedLeftClick(120, 340).Execute<bool>();.
| x | Viewport x to click |
| y | Viewport y to click |
| holdMs | Milliseconds to hold the button down, 0 for an ordinary click |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2322 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.TrustedMiddleClick | ( | int | x, |
| int | y, | ||
| int | holdMs = 0 ) |
Middle clicks a viewport point through the browser's own input pipeline, so the page reads the event as trusted. Answers OK when the click was made and NOTOK where the browser has no debugger to attach, which is Firefox. client.TrustedMiddleClick(120, 340).Execute<bool>();.
| x | Viewport x to click |
| y | Viewport y to click |
| holdMs | Milliseconds to hold the button down, 0 for an ordinary click |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2348 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.Until | ( | Func< bool > | condition | ) |
Executes workflows until condition holds.
| condition | The condition function |
Implements GenerallyPositive.IAllowRESTWorkflow.
Definition at line 1828 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.While | ( | Func< bool > | condition | ) |
Executes workflows while condition holds client.While(() => someCondition).Execute();.
| condition | The condition function |
Implements GenerallyPositive.IAllowRESTWorkflow.
Definition at line 1778 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WindowInnerHeight | ( | ) |
Gets the window inner height client.WindowInnerHeight().Execute<int>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2730 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WindowInnerWidth | ( | ) |
Gets the window inner width client.WindowInnerWidth().Execute<int>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2741 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WindowOuterHeight | ( | ) |
Gets the window outer height client.WindowOuterHeight().Execute<int>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2752 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WindowOuterWidth | ( | ) |
Gets the window outer width client.WindowOuterWidth().Execute<int>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2763 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WindowPageOffsetX | ( | ) |
Gets the window page offset X client.WindowPageOffsetX().Execute<int>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2869 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WindowPageOffsetY | ( | ) |
Gets the window page offset Y client.WindowPageOffsetY().Execute<int>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2880 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WindowScreenLeft | ( | ) |
Gets the window screen left position client.WindowScreenLeft().Execute<int>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2891 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WindowScreenTop | ( | ) |
Gets the window screen top position client.WindowScreenTop().Execute<int>();.
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2902 of file RESTClient.cs.
| IAllowRESTEndpointDetails GenerallyPositive.RESTClient.WithAPIBase | ( | string | url | ) |
Sets the API base URL with download path.
| url | The base URL |
Implements GenerallyPositive.IAllowRESTEndpoint.
Definition at line 279 of file RESTClient.cs.
| IAllowRESTEndpointDetails GenerallyPositive.RESTClient.WithAPIBase | ( | string | url, |
| TimeSpan | httpTimeout ) |
Sets the API base URL and how long one attempt is given before it is abandoned.
| url | The base URL |
| httpTimeout | How long one attempt is given. 60 seconds without this. Pass System.Threading.Timeout.InfiniteTimeSpan for no limit, which is what a call that takes as long as it takes needs |
Implements GenerallyPositive.IAllowRESTEndpoint.
Definition at line 293 of file RESTClient.cs.
| IAllowRESTAttribute GenerallyPositive.RESTClient.WithAttribute | ( | string | attribute | ) |
Specifies the attribute name for get or set operation client.GetAttribute("element123").WithAttribute("value").Execute<string>();.
| attribute | The attribute name |
Implements GenerallyPositive.IAllowRESTAttribute.
Definition at line 2674 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithBody | ( | string | body | ) |
Sets the body of the request being fetched. client.Fetch(url).WithVerb("POST").WithBody(json).Execute();.
| body | Request body |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2809 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithBytes | ( | bool | bytes | ) |
True to bring the fetched response body back base64 encoded, which is what a file needs. Text is the default, and reading a file as text would put a replacement character wherever a byte is not valid utf-8. client.Fetch(url).WithBytes(true).Execute();.
| bytes | True for a base64 encoded body, false for text |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2855 of file RESTClient.cs.
| IAllowRESTCaptureOptions GenerallyPositive.RESTClient.WithCallFilter | ( | string | urlFragment | ) |
Records only the calls whose url holds this, so a page that talks to a dozen places narrows to the one worth having.
| urlFragment | Record only urls holding this |
Implements GenerallyPositive.IAllowRESTCaptureOptions.
Definition at line 3178 of file RESTClient.cs.
| IAllowRESTCaptureOptions GenerallyPositive.RESTClient.WithClearCalls | ( | bool | clear = true | ) |
Forgets what was already recorded before starting, so a second capture is not read as the first.
| clear | True to start from nothing |
Implements GenerallyPositive.IAllowRESTCaptureOptions.
Definition at line 3193 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithContentType | ( | string | contentType | ) |
Sets the content type of the body of the request being fetched. client.Fetch(url).WithContentType("application/json").Execute();.
| contentType | Content type |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2824 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithCss | ( | string | css | ) |
Sets the CSS parameter.
| css | The CSS selector |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 668 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithCssFromResult | ( | int | resultIndex | ) |
Sets the CSS from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 682 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithCssFromResult | ( | string | name | ) |
Sets the CSS from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 701 of file RESTClient.cs.
| IAllowRESTStorageOptions GenerallyPositive.RESTClient.WithData | ( | string | data | ) |
Sets the set storage data parameter.
| data | The data to save in storage |
Implements GenerallyPositive.IAllowRESTStorageOptions.
Definition at line 992 of file RESTClient.cs.
| IAllowRESTStorageOptions GenerallyPositive.RESTClient.WithDeleteAcrossOrigins | ( | bool | crossOrigin | ) |
Implements GenerallyPositive.IAllowRESTStorageOptions.
Definition at line 1077 of file RESTClient.cs.
| IAllowRESTDragAndDrop GenerallyPositive.RESTClient.WithDeltaX | ( | int | deltaX | ) |
Sets the horizontal drop offset for a drag-and-drop operation.
| deltaX | The horizontal offset, in pixels, from the element's current position |
Implements GenerallyPositive.IAllowRESTDragAndDrop.
Definition at line 2005 of file RESTClient.cs.
| IAllowRESTDragAndDrop GenerallyPositive.RESTClient.WithDeltaY | ( | int | deltaY | ) |
Sets the vertical drop offset for a drag-and-drop operation.
| deltaY | The vertical offset, in pixels, from the element's current position |
Implements GenerallyPositive.IAllowRESTDragAndDrop.
Definition at line 2019 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithDeviceName | ( | string | sinkName | ) |
Sets the CSS parameter.
| css | The CSS selector |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1332 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithDownloadFile | ( | string | downloadPath | ) |
Implements GenerallyPositive.IAllowRESTWithDownloadFilename.
Definition at line 2188 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithElement | ( | IGPALElement | gPALElement | ) |
Sets the element parameter.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 721 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithElementId | ( | string | elementId | ) |
Sets the element ID parameter.
| elementId | The element ID |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1878 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithElementIdFromResult | ( | int | resultIndex | ) |
Sets the element from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 737 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithElementIdFromResult | ( | string | name | ) |
Sets the element from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 766 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithEncoding | ( | ContentEncoding | encoding | ) |
Specifiy the encoiding type for posted parameters: json or urlencoded.
| encoding |
Definition at line 1892 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithEndpoint | ( | ApiEndpoint | endpoint | ) |
Sets the endpoint from an ApiEndpoint enum.
| endpoint | The ApiEndpoint enum value |
Implements GenerallyPositive.IAllowRESTEndpointDetails.
Definition at line 316 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithEndpoint | ( | string | endpoint | ) |
Sets the endpoint as a string.
| endpoint | The endpoint string |
Implements GenerallyPositive.IAllowRESTEndpointDetails.
Definition at line 304 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithHeader | ( | string | name, |
| string | value ) |
Adds an HTTP header to the request client.WithHeader("Authorization", "Bearer YOUR_ACCESS_TOKEN").Execute();.
| name | The header name |
| value | The header value |
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1913 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithHeaderFromResult | ( | int | resultIndex | ) |
Sets the header from a result by index.
| resultIndex | The result index |
Definition at line 1964 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithHeaderFromResult | ( | string | name | ) |
Sets the header from a result by name.
| name | The result name |
Definition at line 1984 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithHeaders | ( | string[] | headers | ) |
Sets extra headers for the request being fetched, flattened to name, value, name, value. client.Fetch(url).WithHeaders(new[] { "Accept", "application/json" }).Execute();.
| headers | Header names and values in pairs |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2839 of file RESTClient.cs.
| IAllowRESTScrollElement GenerallyPositive.RESTClient.WithHPixels | ( | int | hPixels | ) |
Sets the horizontal pixels parameter.
| hPixels | The horizontal pixels |
Implements GenerallyPositive.IAllowRESTScrollElement.
Definition at line 2061 of file RESTClient.cs.
| IAllowRESTScrollElement GenerallyPositive.RESTClient.WithHPixelsFromResult | ( | int | resultIndex | ) |
Sets the horizontal pixels from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 2075 of file RESTClient.cs.
| IAllowRESTScrollElement GenerallyPositive.RESTClient.WithHPixelsFromResult | ( | string | name | ) |
Sets the horizontal pixels from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 2094 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithHttpMethod | ( | string | method | ) |
Sets the HTTP method.
| method | The HTTP method |
Implements GenerallyPositive.IAllowRESTMethod.
Definition at line 1292 of file RESTClient.cs.
| IAllowRESTAttribute GenerallyPositive.RESTClient.WithIndex | ( | int | index | ) |
Specifies the option index for select menu operations client.SetAttribute("element123").WithAttribute("disabled").WithValue("true").Execute();.
| value | The attribute value |
Definition at line 1318 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithKey | ( | string | key | ) |
Sets the key parameter.
| key | The key |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 603 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithKeyFromResult | ( | int | resultIndex | ) |
Sets the key from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 618 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithKeyFromResult | ( | string | name | ) |
Sets the key from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 637 of file RESTClient.cs.
| IAllowCheckNetworkIdleOrExecution GenerallyPositive.RESTClient.WithMaxConnections | ( | int | maxConnections | ) |
Sets the maximum connections.
| maxConnections | The maximum connections |
Implements GenerallyPositive.IAllowCheckNetworkIdleOrExecution.
Definition at line 824 of file RESTClient.cs.
| IAllowRESTEndpointDetails GenerallyPositive.RESTClient.WithName | ( | string | name | ) |
Sets the client name.
| name | The client name |
Implements GenerallyPositive.IAllowRESTEndpointDetails.
Definition at line 657 of file RESTClient.cs.
| IAllowRESTDragAndDrop GenerallyPositive.RESTClient.WithOffsetX | ( | int | offsetX | ) |
Sets the horizontal grab offset within the element for a drag-and-drop operation.
| offsetX | Horizontal offset, in pixels, within the element to start the drag from |
Implements GenerallyPositive.IAllowRESTDragAndDrop.
Definition at line 2033 of file RESTClient.cs.
| IAllowRESTDragAndDrop GenerallyPositive.RESTClient.WithOffsetY | ( | int | offsetY | ) |
Sets the vertical grab offset within the element for a drag-and-drop operation.
| offsetY | Vertical offset, in pixels, within the element to start the drag from |
Implements GenerallyPositive.IAllowRESTDragAndDrop.
Definition at line 2047 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithParameters | ( | object | parameters | ) |
Sets parameters as a single object.
| parameters | The parameters object |
Implements GenerallyPositive.IAllowRESTParameters.
Definition at line 933 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithParameters | ( | params object[] | parameters | ) |
Sets parameters as a variable argument list.
| parameters | The parameters |
Implements GenerallyPositive.IAllowRESTParameters.
Definition at line 919 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithParametersFromResult | ( | int | resultIndex | ) |
Sets parameters from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParameters.
Definition at line 947 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithParametersFromResult | ( | string | name | ) |
Sets parameters from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParameters.
Definition at line 969 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithPixels | ( | int | pixels | ) |
Sets the pixels parameter.
| pixels | The pixels value |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1092 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithPixelsFromResult | ( | int | resultIndex | ) |
Sets the pixels from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1106 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithPixelsFromResult | ( | string | name | ) |
Sets the pixels from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1125 of file RESTClient.cs.
| IAllowCheckNetworkIdleOrExecution GenerallyPositive.RESTClient.WithPruneMs | ( | int | pruneMs | ) |
Sets the prune interval in milliseconds.
| pruneMs | The prune interval in milliseconds |
Implements GenerallyPositive.IAllowCheckNetworkIdleOrExecution.
Definition at line 810 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithRangeValue | ( | int | rangeValue | ) |
Specifies the value for SetRange operation client.SetRange("element123").WithRangeValue(63).Execute();.
| rangeValue | The range value |
Implements GenerallyPositive.IAllowRangeValue.
Definition at line 2701 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithReferrer | ( | string | url | ) |
Sets the referrer parameter.
| url | The referrer URL |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1145 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithReferrerFromResult | ( | int | resultIndex | ) |
Sets the referrer from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1159 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithReferrerFromResult | ( | string | name | ) |
Sets the referrer from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1178 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithResultName | ( | string | name | ) |
Sets the result name for the next execution.
| name | The result name |
Implements GenerallyPositive.IAllowRESTEndpointDetails.
Definition at line 478 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithScript | ( | string | script | ) |
Sets the script parameter.
| script | The script |
Definition at line 591 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithSelectIndex | ( | int | selectIndex | ) |
Implements GenerallyPositive.IAllowSelectOptions.
Definition at line 3670 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithSelectValue | ( | string | selectValue | ) |
Set the value to choose from the Select menu.
| value |
Implements GenerallyPositive.IAllowSelectOptions.
Definition at line 3662 of file RESTClient.cs.
| IAllowRESTStorageOptions GenerallyPositive.RESTClient.WithStorageDomain | ( | string | domain | ) |
Sets the storage domain parameter.
| domain | The domain |
Implements GenerallyPositive.IAllowRESTStorageOptions.
Definition at line 1022 of file RESTClient.cs.
| IAllowRESTStorageOptions GenerallyPositive.RESTClient.WithStorageKey | ( | string | key | ) |
Sets the storage key parameter.
| key | The path |
Implements GenerallyPositive.IAllowRESTStorageOptions.
Definition at line 1067 of file RESTClient.cs.
| IAllowRESTStorageOptions GenerallyPositive.RESTClient.WithStoragePath | ( | string | path | ) |
Sets the storage path parameter.
| path | The path |
Implements GenerallyPositive.IAllowRESTStorageOptions.
Definition at line 1037 of file RESTClient.cs.
| IAllowRESTStorageOptions GenerallyPositive.RESTClient.WithStorageStoreName | ( | string | storeName | ) |
Sets the storage domain parameter.
| domain | The domain |
Implements GenerallyPositive.IAllowRESTStorageOptions.
Definition at line 1007 of file RESTClient.cs.
| IAllowRESTStorageOptions GenerallyPositive.RESTClient.WithStorageType | ( | WebsiteStorageType | storageType | ) |
Sets the storage path parameter.
| path | The path |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1052 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithTabId | ( | int | tabId | ) |
Sets the tab ID parameter.
| tabId | The tab ID |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 540 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithTabIdFromResult | ( | int | resultIndex | ) |
Sets the tab ID from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 552 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithTabIdFromResult | ( | string | name | ) |
Sets the tab ID from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 571 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithText | ( | string | text | ) |
Sets the text parameter.
| text | The text |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1198 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithTextFromResult | ( | int | resultIndex | ) |
Sets the text from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1212 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithTextFromResult | ( | string | name | ) |
Sets the text from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 1231 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithTimeout | ( | TimeSpan | httpTimeout | ) |
How long one attempt is given before it is abandoned. Said after the base url, so a client handed a session by ContinueAsRESTClient can still be told, and changed between calls on the same client.
60 seconds unless something says otherwise. A host that accepts the connection and never answers spends the whole of it, so a short one is what to use against a site that may refuse to talk at all. System.Threading.Timeout.InfiniteTimeSpan asks for no limit, for a call that takes as long as it takes. A timeout is not retried, so what is set here is the longest the call can cost.
| httpTimeout | How long one attempt is given |
Implements GenerallyPositive.IAllowRESTExecution.
Definition at line 1947 of file RESTClient.cs.
| IAllowCheckNetworkIdleOrExecution GenerallyPositive.RESTClient.WithTimeoutMs | ( | int | timeoutMs | ) |
Sets the timeout in milliseconds.
| timeoutMs | The timeout in milliseconds |
Implements GenerallyPositive.IAllowCheckNetworkIdleOrExecution.
Definition at line 796 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithUploadFile | ( | string | uploadPath | ) |
Sets the timeout in milliseconds.
| timeoutMs | The timeout in milliseconds |
Implements GenerallyPositive.IAllowRESTWithUploadFilename.
Definition at line 838 of file RESTClient.cs.
| IAllowRESTExecution GenerallyPositive.RESTClient.WithUploadFiles | ( | GPALFile | uploadPaths | ) |
Sets the timeout in milliseconds.
| timeoutMs | The timeout in milliseconds |
Implements GenerallyPositive.IAllowRESTWithUploadFilename.
Definition at line 852 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithUrl | ( | string | url | ) |
Sets the URL parameter.
| url | The URL |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 489 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithUrlFromResult | ( | int | resultIndex | ) |
Sets the URL from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 501 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithUrlFromResult | ( | string | name | ) |
Sets the URL from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 520 of file RESTClient.cs.
| IAllowRESTAttribute GenerallyPositive.RESTClient.WithValue | ( | string | value | ) |
Specifies the value for set operation client.SetAttribute("element123").WithAttribute("disabled").WithValue("true").Execute();.
| value | The attribute value |
Implements GenerallyPositive.IAllowRESTAttribute.
Definition at line 2716 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithVerb | ( | string | method | ) |
Sets the verb of the request being fetched. Not .WithHttpMethod, which is the verb of the REST call itself. GET when nothing was said. client.Fetch(url).WithVerb("POST").Execute();.
| method | HTTP verb for the fetched request |
Implements GenerallyPositive.IAllowRestMethods.
Definition at line 2794 of file RESTClient.cs.
| IAllowRESTScrollElement GenerallyPositive.RESTClient.WithVPixels | ( | int | vPixels | ) |
Sets the vertical pixels parameter.
| vPixels | The vertical pixels |
Implements GenerallyPositive.IAllowRESTScrollElement.
Definition at line 2114 of file RESTClient.cs.
| IAllowRESTScrollElement GenerallyPositive.RESTClient.WithVPixelsFromResult | ( | int | resultIndex | ) |
Sets the vertical pixels from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 2128 of file RESTClient.cs.
| IAllowRESTScrollElement GenerallyPositive.RESTClient.WithVPixelsFromResult | ( | string | name | ) |
Sets the vertical pixels from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 2147 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithWindowId | ( | int | windowId | ) |
Sets the window ID parameter client.CloseWindow(123).Execute<WindowTuple>();.
| windowId | The window ID |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 3765 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithWindowIdFromResult | ( | int | resultIndex | ) |
Sets the window ID from a result by index client.GoToWindow().WithWindowIdFromResult(0).Execute<WindowTuple>();.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 3777 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithWindowIdFromResult | ( | string | name | ) |
Sets the window ID from a result by name client.GoToWindow().WithWindowIdFromResult("windowResult").Execute<WindowTuple>();.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 3796 of file RESTClient.cs.
| IAllowRESTWorkflow GenerallyPositive.RESTClient.WithWorkflow | ( | Action< RESTClient > | workflow | ) |
Adds a workflow definition client.WithWorkflow(c => c.WithEndpoint(...).Execute()).While(...);.
| workflow | The workflow action |
Implements GenerallyPositive.IAllowRESTWorkflow.
Definition at line 1757 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithXPath | ( | string | xpath | ) |
Sets the XPath parameter.
| xpath | The XPath |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 866 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithXPathFromResult | ( | int | resultIndex | ) |
Sets the XPath from a result by index.
| resultIndex | The result index |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 880 of file RESTClient.cs.
| IAllowRESTParametersOrExecution GenerallyPositive.RESTClient.WithXPathFromResult | ( | string | name | ) |
Sets the XPath from a result by name.
| name | The result name |
Implements GenerallyPositive.IAllowRESTParametersOrExecution.
Definition at line 899 of file RESTClient.cs.
|
getset |
Gets or sets the client name.
Implements GenerallyPositive.IRESTClient.
Definition at line 268 of file RESTClient.cs.
|
get |
The seconds the last call was asked to wait before asking again, zero when it was not asked.
Implements GenerallyPositive.IRESTClient.
Definition at line 76 of file RESTClient.cs.
|
get |
The HTTP status code the last call came back with.
Implements GenerallyPositive.IRESTClient.
Definition at line 71 of file RESTClient.cs.