Skip to content

Commit

Permalink
Merge pull request #2401 from SwedbankPay/release/5.3.3
Browse files Browse the repository at this point in the history
Release 5.3.3 (master)
  • Loading branch information
arebra authored Dec 9, 2024
2 parents 30cb424 + e30d231 commit 7ad37c4
Show file tree
Hide file tree
Showing 35 changed files with 1,340 additions and 1,424 deletions.
24 changes: 12 additions & 12 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,9 @@ GEM
gemoji (>= 3, < 5)
html-pipeline (~> 2.2)
jekyll (>= 3.0, < 5.0)
json (2.7.2)
kramdown (2.4.0)
rexml
json (2.9.0)
kramdown (2.5.1)
rexml (>= 3.3.9)
kramdown-parser-gfm (1.1.0)
kramdown (~> 2.0)
kramdown-plantuml (1.3.3)
Expand All @@ -106,7 +106,7 @@ GEM
racc (~> 1.4)
open3 (0.1.2)
parallel (1.26.3)
parser (3.3.5.0)
parser (3.3.6.0)
ast (~> 2.4.1)
racc
pathutil (0.16.2)
Expand All @@ -118,9 +118,9 @@ GEM
rb-fsevent (0.11.2)
rb-inotify (0.11.1)
ffi (~> 1.0)
regexp_parser (2.9.2)
rexml (3.3.7)
rouge (4.4.0)
regexp_parser (2.9.3)
rexml (3.3.9)
rouge (4.5.1)
rspec (3.13.0)
rspec-core (~> 3.13.0)
rspec-expectations (~> 3.13.0)
Expand All @@ -134,17 +134,17 @@ GEM
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.13.0)
rspec-support (3.13.0)
rubocop (1.67.0)
rubocop (1.69.1)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
parallel (~> 1.10)
parser (>= 3.3.0.2)
rainbow (>= 2.2.2, < 4.0)
regexp_parser (>= 2.4, < 3.0)
rubocop-ast (>= 1.32.2, < 2.0)
regexp_parser (>= 2.9.3, < 3.0)
rubocop-ast (>= 1.36.2, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
rubocop-ast (1.32.3)
unicode-display_width (>= 2.4.0, < 4.0)
rubocop-ast (1.36.2)
parser (>= 3.3.1.0)
rubocop-rake (0.6.0)
rubocop (~> 1.0)
Expand Down
8 changes: 7 additions & 1 deletion _includes/autoclick.md
Original file line number Diff line number Diff line change
Expand Up @@ -373,7 +373,13 @@ api-supported-versions: 3.x/2.0{% endcapture %}
"rel": "abort",
"method": "PATCH",
"contentType": "application/json"
}
}{% if documentation_section contains "checkout-v3" %},
{
"href": "https://api.payex.com/psp/paymentorders/{{ page.payment_order_id }}",
"rel": "abort-paymentattempt",
"method": "PATCH",
"contentType": "application/json"
}{% endif %}
]
}{% endcapture %}

Expand Down
8 changes: 7 additions & 1 deletion _includes/checkout-v3-status-models.md
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,13 @@ api-supported-versions: 3.x{% endcapture %}
"rel": "abort",
"method": "PATCH",
"contentType": "application/json"
}
}{% if documentation_section contains "checkout-v3" %},
{
"href": "https://api.payex.com/psp/paymentorders/{{ page.payment_order_id }}",
"rel": "abort-paymentattempt",
"method": "PATCH",
"contentType": "application/json"
}{% endif %}
]
}{% endcapture %}

Expand Down
8 changes: 7 additions & 1 deletion _includes/instrument-mode.md
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,13 @@ api-supported-versions: 3.x/2.0{% endcapture %}
"rel": "abort",
"method": "PATCH",
"contentType": "application/json"
},
},{% if documentation_section contains "checkout-v3" %}
{
"href": "https://api.payex.com/psp/paymentorders/{{ page.payment_order_id }}",
"rel": "abort-paymentattempt",
"method": "PATCH",
"contentType": "application/json"
},{% endif %}
{
"href": "https://api.payex.com/psp/paymentorders/222a50ca-b268-4b32-16fa-08d6d3b73224",
"rel": "set-instrument",
Expand Down
33 changes: 12 additions & 21 deletions _includes/metadata.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,17 @@
{% capture api_resource %}{% include api-resource.md %}{% endcapture %}

{% if api_resource == "paymentorders" %}
{% assign api_resource_title="payment order" %}
{% else %}
{% assign api_resource_title="payment" %}
{% endif %}
{% capture documentation_section %}{%- include utils/documentation-section.md -%}{% endcapture %}

## Metadata

Metadata can be used to store data associated to a {{ api_resource_title }}
that can be retrieved later by performing a `GET` on the
{{ api_resource_title }}.
Swedbank Pay does not use or process `metadata`, it is only stored on the
{{ api_resource_title }} so it can be retrieved later alongside the
{{ api_resource_title }}. An example where `metadata` might be useful is when
several internal systems are involved in the payment process, and the payment
creation is done in one system and post-purchases take place in another.
In order to transmit data between these two internal systems, the data can be
stored in `metadata` on the {{ api_resource_title }} so the internal systems do
not need to communicate with each other directly. The usage of `metadata` field
is shown in the abbreviated `Purchase` request below.
Metadata can be used to store data associated to a payment that can be retrieved
later by performing a `GET`. Swedbank Pay does not use or process `metadata`, it
is only stored on the payment so it can be retrieved later. An example where
`metadata` might be useful is when several internal systems are involved in the
payment process, and the payment creation is done in one system and
post-purchases take place in another. In order to transmit data between these
two internal systems, the data can be stored in `metadata` on the payment so the
internal systems do not need to communicate with each other directly. The usage
of `metadata` field is shown in the abbreviated `Purchase` request below.

## Metadata Request

Expand Down Expand Up @@ -72,15 +64,14 @@ Content-Type: application/json{% endcapture %}

## GET Request

{% capture request_header %}GET /psp/{{ api_resource }}/{% unless api_resource == "paymentorders" %}payments/{% endunless %}{{ page.payment_id }}/ HTTP/1.1
{% capture request_header %}POST /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 %}

{% include code-example.html
title='Request'
title='GET Request'
header=request_header
json= request_content
%}

## GET Response
Expand Down
8 changes: 7 additions & 1 deletion _includes/payer-aware-payment-menu.md
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,13 @@ api-supported-versions: 3.x/2.0{% endcapture %}
"rel": "abort",
"method": "PATCH",
"contentType": "application/json"
}
}{% if documentation_section contains "checkout-v3" %},
{
"href": "https://api.payex.com/psp/paymentorders/{{ page.payment_order_id }}",
"rel": "abort-paymentattempt",
"method": "PATCH",
"contentType": "application/json"
}{% endif %}
]
}{% endcapture %}

Expand Down
10 changes: 9 additions & 1 deletion _includes/payment-order-3-1.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ Content-Type: application/json;version=3.1{% endcapture %}
"completeUrl": "https://example.com/payment-completed",
"cancelUrl": "https://example.com/payment-cancelled", //Redirect only
"callbackUrl": "https://api.example.com/payment-callback",
"logoUrl": "https://example.com/logo.png"
"logoUrl": "https://example.com/logo.png",
"termsOfServiceUrl": "https://example.com/termsandconditoons.pdf"
},
"payeeInfo": {
"payeeId": "{{ page.merchant_id }}",
Expand Down Expand Up @@ -61,6 +62,7 @@ Content-Type: application/json;version=3.1{% endcapture %}
| {% icon check %} | {% f cancelUrl, 2 %} | `string` | The URL to redirect the payer to if the payment is cancelled, either by the payer or by the merchant trough an `abort` request of the `payment` or `paymentorder`. |
| {% icon check %} | {% f callbackUrl, 2 %} | `string` | {% include fields/callback-url.md %} |
| | {% f logoUrl, 2 %} | `string` | {% include fields/logo-url.md %} |
| | {% f termsOfServiceUrl, 2 %} | `string` | {% include fields/terms-of-service-url.md %} |
| {% icon check %} | {% f payeeInfo %} | `object` | {% include fields/payee-info.md %} |
| {% icon check %} | {% f payeeId, 2 %} | `string` | The ID of the payee, usually the merchant ID. |
| {% icon check %} | {% f payeeReference, 2 %} | `string` | {% include fields/payee-reference.md describe_receipt=true %} |
Expand Down Expand Up @@ -168,6 +170,12 @@ api-supported-versions: 3.x/2.0{% endcapture %}
"rel": "abort",
"method": "PATCH",
"contentType": "application/json"
},
{
"href": "https://api.payex.com/psp/paymentorders/{{ page.payment_order_id }}",
"rel": "abort-paymentattempt",
"method": "PATCH",
"contentType": "application/json"
}
]
}{% endcapture %}
Expand Down
Loading

0 comments on commit 7ad37c4

Please sign in to comment.