From b96921798bfed269d91c1201460010c948bcd0e1 Mon Sep 17 00:00:00 2001 From: Stef Heyenrath Date: Fri, 12 May 2017 22:28:35 +0200 Subject: [PATCH] Updated Record (via proxy) AndSave (markdown) --- Record-(via-proxy)-AndSave.md | 1 - Record-(via-proxy)-and-Save.md | 14 ++++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) delete mode 100644 Record-(via-proxy)-AndSave.md create mode 100644 Record-(via-proxy)-and-Save.md diff --git a/Record-(via-proxy)-AndSave.md b/Record-(via-proxy)-AndSave.md deleted file mode 100644 index 7f5187d..0000000 --- a/Record-(via-proxy)-AndSave.md +++ /dev/null @@ -1 +0,0 @@ -##sadsd \ No newline at end of file diff --git a/Record-(via-proxy)-and-Save.md b/Record-(via-proxy)-and-Save.md new file mode 100644 index 0000000..0a9c7dc --- /dev/null +++ b/Record-(via-proxy)-and-Save.md @@ -0,0 +1,14 @@ +# Record (via proxy) and Save + +You can enable ProxyAndRecord functionality by defining the *ProxyAndRecordSettings* and by specifying an Url. See code example below. + +```c# +var server = FluentMockServer.Start(new FluentMockServerSettings +{ + Urls = new[] { "http://localhost:9095/" }, + StartAdminInterface = true, + ProxyAndRecordSettings = new ProxyAndRecordSettings { Url = "http://www.bbc.com" } +}); +``` + +When you a request like `localhost:9095/earth/story/20170510-terrifying-20m-tall-rogue-waves-are-actually-real`, this request is proxied to the `bbc.com` and the mapping definition is saved to `__admin\mappings\ab38efae-4e4d-4f20-8afe-635533ec2535.json`. \ No newline at end of file