Skip to content

Commit

Permalink
Merge pull request #2403 from SwedbankPay/feature/devp-506_fix_get_re…
Browse files Browse the repository at this point in the history
…quest_code_examples

DEVP-506: Fixed code-example.html in GET requests
  • Loading branch information
arebra authored Dec 12, 2024
2 parents 8290f5b + d8e7a14 commit e994fef
Show file tree
Hide file tree
Showing 36 changed files with 1 addition and 60 deletions.
1 change: 0 additions & 1 deletion _includes/authorizations.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% include transaction-list-response.md transaction="authorization" %}
Expand Down
1 change: 0 additions & 1 deletion _includes/capture.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% include transaction-list-response.md api_resource=include.api_resource documentation_section=include.documentation_section transaction="capture" %}
Expand Down
1 change: 0 additions & 1 deletion _includes/card-authorization-transaction.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

## GET Authorization Response
Expand Down
1 change: 0 additions & 1 deletion _includes/card-payments-capture.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% include transaction-list-response.md transaction="capture" %}
Expand Down
1 change: 0 additions & 1 deletion _includes/checkout-v2-resource-models.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ Content-Type: application/json;version=2.0 // Version optional for 2.0{% en
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

### Card `Paid` Resource
Expand Down
9 changes: 0 additions & 9 deletions _includes/checkout-v3-resource-models.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down Expand Up @@ -51,7 +50,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down Expand Up @@ -137,7 +135,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down Expand Up @@ -196,7 +193,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down Expand Up @@ -302,7 +298,6 @@ Accept: application/json;version=3.x{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down Expand Up @@ -383,7 +378,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down Expand Up @@ -486,7 +480,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down Expand Up @@ -726,7 +719,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

### Card `Paid` Resource
Expand Down Expand Up @@ -1313,7 +1305,6 @@ Content-Type: application/json;version=3.x{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

### Card `Reversed` Resource
Expand Down
1 change: 0 additions & 1 deletion _includes/checkout-v3-status-models.md
Original file line number Diff line number Diff line change
Expand Up @@ -1011,7 +1011,6 @@ Content-Type: application/json;version=3.x{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

### Card `Reversed` Resource
Expand Down
1 change: 0 additions & 1 deletion _includes/expand-parameter.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,4 @@ Host: {{ page.api_host }}{% endcapture %}
{% include code-example.html
title='Expansion'
header=request_header
json= request_content
%}
1 change: 0 additions & 1 deletion _includes/integrated-commerce.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

## QUERY Request
Expand Down
1 change: 0 additions & 1 deletion _includes/invoice-capture.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

## GET Capture Response
Expand Down
2 changes: 1 addition & 1 deletion _includes/metadata.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ Content-Type: application/json{% endcapture %}

## GET Request

{% capture request_header %}POST /psp/{{ api_resource }}/{% unless api_resource == "paymentorders" %}payments/{% endunless %}{{ page.payment_id }}/ HTTP/1.1
{% capture request_header %}GET /psp/{{ api_resource }}/{% unless api_resource == "paymentorders" %}payments/{% endunless %}{{ page.payment_id }}/ HTTP/1.1
Host: {{ page.api_host }}
Authorization: Bearer <AccessToken>
Content-Type: application/json{% endcapture %}
Expand Down
1 change: 0 additions & 1 deletion _includes/network-tokenization.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='GET Tokens Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down
3 changes: 0 additions & 3 deletions _includes/one-click-payments.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,6 @@ Authorization: Bearer <AccessToken>{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% else %}
Expand All @@ -105,7 +104,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Get Request Payment Resource'
header=request_header
json= request_content
%}

You can also perform a GET request towards the `id` of a Payment Order and find
Expand All @@ -119,7 +117,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='GET Request Paid Resource'
header=request_header
json= request_content
%}

{% endif %}
Expand Down
2 changes: 0 additions & 2 deletions _includes/payee-info.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% else %}
Expand All @@ -40,7 +39,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% endif %}
Expand Down
1 change: 0 additions & 1 deletion _includes/payment-order-after-payment.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

## GET Response
Expand Down
1 change: 0 additions & 1 deletion _includes/payment-order-get.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

## GET Payment Order Response
Expand Down
3 changes: 0 additions & 3 deletions _includes/payment-order-recur.md
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

As an alternative, you can also retrieve it by using the expand option when you
Expand All @@ -395,7 +394,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% else %}
Expand All @@ -413,7 +411,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% endif %}
Expand Down
3 changes: 0 additions & 3 deletions _includes/payment-order-unscheduled.md
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

As an alternative, you can also retrieve it by using the expand option when you
Expand All @@ -402,7 +401,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% else %}
Expand All @@ -420,7 +418,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% endif %}
Expand Down
1 change: 0 additions & 1 deletion _includes/payment-resource.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

## GET Payment Resource Response
Expand Down
2 changes: 0 additions & 2 deletions _includes/payments-operations.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% if documentation_section == "card" %}
Expand Down Expand Up @@ -244,7 +243,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down
1 change: 0 additions & 1 deletion _includes/prices.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

## GET Prices Response
Expand Down
1 change: 0 additions & 1 deletion _includes/reversal.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% include transaction-list-response.md api_resource=include.api_resource documentation_section=include.api_resource transaction="reversal" %}
Expand Down
2 changes: 0 additions & 2 deletions _includes/transaction.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0 a
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down Expand Up @@ -77,7 +76,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down
2 changes: 0 additions & 2 deletions _includes/transactions.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0 a
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% else %}
Expand All @@ -46,7 +45,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% endif %}
Expand Down
2 changes: 0 additions & 2 deletions _includes/unscheduled-purchase.md
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

As an alternative, you can also retrieve it by using the expand option when you
Expand All @@ -396,7 +395,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

## Performing The Unscheduled Purchase
Expand Down
1 change: 0 additions & 1 deletion _includes/urls.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0 a
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down
1 change: 0 additions & 1 deletion _includes/vipps-payments-capture.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ Content-Type: application/json{% endcapture %}
{% include code-example.html
title='Request'
header=request_header
json= request_content
%}

{% include transaction-list-response.md transaction="capture" %}
Expand Down
1 change: 0 additions & 1 deletion checkout-v3/get-started/fundamental-principles.md
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,6 @@ Host: {{ page.api_host }}{% endcapture %}
{% include code-example.html
title='HTTP Request with expansion'
header=request_header
json= request_content
%}

To avoid unnecessary overhead, you should only expand the fields you need info
Expand Down
2 changes: 0 additions & 2 deletions checkout-v3/get-started/validate-status.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='GET Request with expanded paid node'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down Expand Up @@ -189,7 +188,6 @@ Content-Type: application/json;version=3.x/2.0 // Version optional for 3.0
{% include code-example.html
title='GET Request directly towards the paid resource'
header=request_header
json= request_content
%}

{% capture response_header %}HTTP/1.1 200 OK
Expand Down
Loading

0 comments on commit e994fef

Please sign in to comment.